Meego Wiki
Views
From MeeGo wiki
< SDK
Revision as of 10:06, 24 November 2010 by Zhiyuan (Talk | contribs)
Jump to: navigation, search

Note: This page contains instructions on install MeeGo SDK for Windows, and use it to build/deploy/debug apps. MeeGo SDK for Windows has not been released yet, and it is still under development.

Contents

Latest status

Nov 15, 2010

  • Issues to be closed before official release:
    • Go through license process and sign the installer (bug #9346, #9618, owner: Veli)

Nov 14, 2010

  • Latest installer was released at today with version number 1112. Main changes:
    • MADDE updated to commit 14c12d00deb848419b96e5ad5e566d500703c44f.
      • QEMU IA images updated to latest version.
    • An online installer is included.
  • I did some smoke test with it, while it has not been tested by QA yet.

Maxayu 03:16, 15 November 2010 (UTC)

History status

Check SDK/History Status of MeeGo SDK for Windows for more history status.

How to contribute

Report bugs

  • URL: http://bugs.meego.com .
  • Product name: MeeGo SDK
  • Bug summary: Please have "[Windows]" in the begining of your bug summary.

Update document

The current wiki page is the official document for MeeGo SDK for Windows. Feel free to edit it.

System requirements

  • Windows XP and Windows 7 are officially supported by MeeGo SDK. MeeGo SDK may work on Windows Vista, but it is not officially supported.
  • MeeGo SDK should be installed to hardlink-capable filesystem such as NTFS. FAT* filesystems are not hardlink-capable, so they are not supported.
  • Emulator can only work with 32-bit Windows. If you are using 64-bit Windows, you cannot use emulator.

Known issues and possible workarounds

  • Currently the emulator only works for the IA target.
  • Only one target "meego-handset-ia32-w32-1.1" and one runtime "meego-handset-ia32-pinetrail-mtf-1.0.90.2.20100914.1-sdk-1.1.80.20101023.1936-sda-runtime" has been tested.
  • All stuff, including targets and runtimes, will be removed if you run the uninstaller of MeeGo SDK.

Download and setup the MeeGo SDK

  1. Download the MeeGo SDK installer:
  2. FileDescriptionSizeMD5SUM
    http://download3.meego.com/MeeGoSDK/meego-1.1-sdk-online-installer-1119-2.exe MeeGo SDK Windows online installer 14MB 39e15eec6a7ef5a46cbf85fa1a733cae
    http://download3.meego.com/MeeGoSDK/meego-1.1-sdk-offline-installer-1119-2.exe MeeGo SDK Windows offline installer 54MB 57862b2edcd2a694e2443b6273c1bc48
  3. Double-click on the downloaded .exe file and follow the prompts to install the SDK.
  4. After installation, launch MADDE Terminal with Start > All Programs > MeeGo SDK > MADDE Terminal.
    1. Run something like "export http_proxy=XXX" if you are in an intranet.
    2. Run "mad-admin create -f meego-handset-ia32-w32-1.1" to create target "meego-handset-ia32-w32-1.1". Some huge files will be downloaded automatically.
    3. Run "mad-admin create -e -f meego-handset-ia32-w32-qemu-1.1.20101031.2201-sda-runtime" to create a runtime "meego-handset-ia32-w32-qemu-1.1.20101031.2201-sda-runtime". Some huge files will be downloaded automatically.
  5. Launch Qt Creator with Start > All Programs > MeeGo SDK > QtCreator.
  6. Configure Qt Creator to support MeeGo sysroot. Inside Qt Creator, follow these steps:
    1. From the Tools menu, choose Options.
    2. Click into the Qt4 section, and make sure the Qt Versions tab is open.
    3. Click the + button, and then fill the Version name and the qmake location of the MeeGo target:
      • Version name: meego-handset
      • qmake location: <MEEGO_SDK>\MADDE\targets\<target name>\bin\qmake.exe
        Replace <MEEGO_SDK> with the directory where you installed MeeGo SDK; the default is C:\MeeGoSDK_1.1; replace <target_name> with the name of the target (for example, meego-core-ia32).
      • Once added, select the new entry and click on the Rebuild button (bottom right) to build the debugging helper for this Qt version. This enables you to use debugging from Qt Creator.

      The result should look like this:
      Meego-sdk-qt4.png

Use Qt Creator to develop MeeGo Applications

  1. Create a MeeGo touch project (for handset) or Qt Gui project (for netbook)
  2. Go to the menu: File -> New File or Project -> Qt Application Project -> Meego Touch Framework Application.
    Windows sdk 2.png

    In "Project setup" dialog, choose "meego-handset".

    Meego-sdk-project-setup.png

  3. Set up emulator: Install kqemu accelerator for QEMU on 32-bit Windows system
  4. Notice: The kqemu could only be used on 32-bit Windows. 64-bit Windows could not work with kqemu. You can not use emulator on 64-bit Windows. Use real device instead.

    Download package from http://wiki.qemu.org/download/kqemu-1.4.0pre1.tar.gz

    Get the kqemu.inf and kqemu.sys files from above package

    For Windows XP system, right click the kqemu.inf file and select "install".

    For Windows 7 or Windows Vista system, edit the kqemu.inf file to do below changes, and then right click the kqemu.inf, select "install".

      [DefaultInstall.NT] --> [DefaultInstall]
      [DefaultInstall.NT.Services] --> [DefaultInstall.Services]
      [Uninstall.NT] --> [Uninstall]
      [Uninstall.NT.Services] --> [Uninstall.Services]
    

    Start the kqemu manually. Select Start > All Programs > Accessories, click right mouse button over Command Prompt, and select "Run as administrator". In Command Prompt, run the following command:

    net start kqemu
    

    You need to start kqemu again after you reboot the system.


  5. Create an emulator runtime for MeeGo

  6. Get to the menu: Tools -> Options -> Projects -> MeeGo Device Configurations. Click "Add" button to add a runtime for emulator. Set "Device type" to "MeeGo emulator"; set "Authentication type" to "Password"; set "Username" to "root"; set "Password" to "meego".
    Meego-sdk-emulator.png

  7. Set Run Configuration
  8. Click "Projects" again on the left side. Select "Run" in the MeeGo Build/Run box at the top. Make sure that the "Device configuration" is set to "MeeGo Emulator". This will ensure that QEMU is started when you run your application. You can now launch the QEMU MeeGo emulator. Click the "Start Meego emulator" icon near the bottom left corner of Qt Creator (circled in red in the screenshot below).
    Meego-sdk-run-settings.png

  9. Build, run and deploy the application
  10. After QEMU starts, click the "Run" icon to run your application. Qt Creator will package and deploy your application to QEMU and start it on the target. You can see the window of your application in QEMU.
    Qemu-handset.png


  11. Debug the application
  12. You can also debug the application by clicking the "Debug" icon. Setting breakpoints and stepping are the same as local applications.
    Qemu-handset-debug.png

SSH into QEMU Image

Anytime MeeGo is running in QEMU, you can use SSH to connect to the image from another terminal on the host system.

  1. Launch QEMU with MeeGo image (step #5 above)
  2. From a terminal on the host, connect to the running image
  3. $ ssh meego@127.0.0.1 -p 6666
    

Two user accounts are available in the MeeGo images:
User: meego Password: meego
User: root      Password: meego

Configure Qt Creator to work with real devices

Qt Creator working with QEMU is out of the box, but sometimes we need to work with real device. Here is how:

  1. Go to Tools -> Options -> Projects -> MeeGo Device Configurations and click "Add" button. Select "Remote Device" for "Device type", input other information and give a name for this configuration
  2. Real-device.png

  3. Open your project and in the "Projects" mode, click "Run" in the little MeeGo target window, and select the configuration you just created in "Device Configuration"
  4. Meego-sdk-run-settings-real-device.png

  5. Launch terminal inside the device, and run command "xhost +" in it.
  6. Click "Run" or "Debug" on the lower left corner of Qt Creator to run or debug your application on the configured Device.

More information about QEMU images used by SDK for windows

The QEMU images for SDK on Linux could be built from the ks file in http://meego.gitorious.org/meego-os-base/image-configurations/trees/MeeGo1.1/SDK, by using mic-image-creator tool (command to run the mic-image-creator could be found in each ks file). Ideally the images are host platform independent, however, due to the booting time and some other issues with kqemu, minor changes were done on the images obtained from ks file so that they could boot up successfully on Windows. Suppose you have had a raw image, say abc.raw, built from kick start file in hand, below are the changes needed:

1, mount into the image

sudo mount -o loop,offset=512 abc.raw /mnt

2, edit usr/sbin/meego-dm to add "sleep 1" so that mouse udev could be ready before X server starting up.

sleep 1    # new added line
shopt -s execfail

3, edit boot/extlinux/extlinux.conf to add kernel option "intel_idle.max-cstate=0" to solve http://bugs.meego.com/show_bug.cgi?id=10149

append ro root=/dev/sda1 vga=current intel_idle.max-cstate=0 quiet

4, unmount the image

sudo umount /mnt
Personal tools