MeeGo SDK, I presume?

Finally. On the aftermath of MeeGo Summit FI (which was great!), managed to find some time for getting to know and trying out the MeeGo SDK on Linux. There’s a subtle possibility that having an ExoPC has something to do with a sudden appearance of extra hacking time. Decided to put down some notes in case somebody else might find them useful.

Starting point:

Installing the SDK

The first step was to install the MeeGo SDK, and having the meego-sdk metapackage available for Ubuntu (among other supported distros) made the installation rather straightforward. See the SDK instructions for details, it’s just add repo -> get the PGP key -> update repos -> install meego-sdk.

Target setup

When the SDK was installed, it was time to move into creating a target for compiling things for MeeGo. In the SDK, there are targets, and runtimes. A target contains the toolchain and libraries for a MeeGo environment, and a runtime is the OS image which can run the compiled applications on the PC using QEMU. As there was hardware available, I only used the target.

Actually can’t remember if the SDK installation set up the meego-netbook target ready on the first install, but let’s now just assume it didn’t.

Installed and installable targets can be shown with mad-admin list, and the output is something like this:

fremantle-pr13              (installable)
maemo412-1                  (installable)
meego-core-armv7l-1.1       (installable)
meego-core-armv7l-1.1.2     (installable)
meego-core-armv7l-trunk     (installable)
meego-core-ia32-1.1         (installable)
meego-core-ia32-trunk       (installable)
meego-handset-ia32-1.1.2    (installable)
meego-handset-ia32-1.1      (installable)
meego-handset-ia32-w32-1.1  (installable)
meego-handset-ia32-trunk    (installable)
meego-netbook-ia32-1.1.2    (installable)
meego-netbook-ia32-1.1      (installed)
meego-netbook-ia32-w32-1.1  (installable)
meego-netbook-ia32-trunk    (installable)

For the case of ExoPC, I selected the meego-netbook-ia32-1.1. Tried meego-netbook-ia32-trunk too, but that wasn’t working, only got this:

  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 –:–:– –:–:– –:–:–     0
Warning: Transient problem: FTP error Will retry in 1 seconds. 5 retries left.
  0     0    0     0    0     0      0      0 –:–:– –:–:– –:–:–     0
Warning: Transient problem: FTP error Will retry in 2 seconds. 4 retries left.
  0     0    0     0    0     0      0      0 –:–:– –:–:– –:–:–     0
Warning: Transient problem: FTP error Will retry in 4 seconds. 3 retries left.

So, target was installed with sudo mad-admin create -f meego-netbook-ia32-1.1. This downloaded the target contents and set them up under /usr/lib/madde/linux-i686/targets/meego-netbook-ia32-1.1. That folder contains some necessary tools, such as qmake, and Qt libs. There’s also a file called information which shows the building blocks of the target:

sysroot meego-core-ia32-madde-sysroot-1.1-fs
toolchain meego-sdk-i586-toolchain-1.1-linux_i686
runtime meego-netbook-ia32-qemu-1.1.20101031.2037-sda-runtime
qttools qt-tools-4.7.0-linux_i686
os Linux
arch i586

That sysroot can be found under /usr/lib/madde/linux-i686/sysroots/ and the toolchain is in /toolchains directory under linux-i686.

Qt Creator configuration

Now that the target was setup, and meego-sdk-qtcreator was present, it was time to launch it. First step, is to set the Qt path, see section “Configuring Qt Creator to use the MeeGo toolchain(s)” in the SDK wiki page. Now that Qt is found, apps can be compiled for the tablet \o/.

Configuring the ExoPC for deployment/debug support

For this to work, you’ve got to have the host PC and the tablet in the same network, WLAN being the most obvious choice. The tablet has an SSH daemon running from the boot and the IP address can be viewed in the WiFi Settings screen. (Pssst: Password for root&meego users is meego).

In the MeeGo Qt Creator, go to Tools->Options->Projects->MeeGo Device Configurations. Settings needed:

  • Authentication type: Password
  • Host name: <ExoPC’s IP> <– TODO: Configuring a static IP for the tablet
  • Username: root
  • Password: meego

Also deployed a public SSH key to the ExoPC, but for some reason the connection is just failing after that with “Device configuration test failed: Could not connect to host.”.

After the settings are done, click Apply and then click Test to see if everything is working. You should see a dialog saying “Device configuration successful” and info about the kernel version & installed Qt packages.

Time to compile some software!

For the first testrun, I chose the fingerpaint example found in Qt 4.7 under Examples/4.7/touch/fingerpaint. Open the project, and choose the Qt version you set up above as the build target.

For deployment to the device, see the Projects tab, and select the freshly setup Device Configuration in the Run configuration under the MeeGo build target.

There was one thing i had to customize: at least for the fingerpaint example, the RPM package which is created by Qt Creator tries to find the binary in /usr/local/bin, and starting the application fails via the run button (The green Play button). To make it work, go to the Projects tab again, and edit the Build configuration. Change the Create Package Step. Click Details and change the Remote File Path to /usr/share/qt4/examples/touch/fingerpaint/fingerpaint.

Now clicking the Run button should bring up this:

Since the device configuration has been done and deployment works, also on-device-debugging is rolling on nicely.

That’s all this time, happy hacking!

About sandst1
A technology-oriented guy interested in all-round creativity, be it music, art, or putting software together for creating something new and expressing oneself

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: