Meego Wiki
Views

SDK/Docs/1.1/Getting started with the MeeGo SDK for Linux

From MeeGo wiki
(Difference between revisions)
Jump to: navigation, search
(Promote SDK installation as a whole. Remove individual package components.)
Line 9: Line 9:
== Prerequisites ==
== Prerequisites ==
-
* To use the MeeGo SDK, you should be running a reasonably modern Linux distribution (such as [https://fedoraproject.org/en/index Fedora 13], [http://www.ubuntu.com/ Ubuntu 10.04 LTS], [http://www.opensuse.org/en/ openSUSE 11.3]) on reasonably modern hardware, such as 32-bit Intel Atom or Intel Core 2 CPU.
+
* To use the MeeGo SDK, you should be running a reasonably modern Linux distribution.  Currently the MeeGo 1.1 SDK has been validated on [https://fedoraproject.org/en/index Fedora 12, Fedora 13], [http://www.ubuntu.com/ Ubuntu 9.10, and Ubuntu 10.04 LTS].  Other distributions such as [http://www.opensuse.org/en/ openSUSE 11.x] and Windows XP are planned for support soon.  In addition, you should run on reasonably modern hardware, such as 32-bit Intel Atom or Intel Core 2 CPU.
* If you intend to [[SDK/Docs/1.1/Configuring QEMU runtimes|use QEMU]], you will get reasonable performance only if your host system has VT support. See [[SDK/Docs/1.1/MeeGo_SDK_Graphics_Acceleration|this page]] for details of how to check your system's capabilities.
* If you intend to [[SDK/Docs/1.1/Configuring QEMU runtimes|use QEMU]], you will get reasonable performance only if your host system has VT support. See [[SDK/Docs/1.1/MeeGo_SDK_Graphics_Acceleration|this page]] for details of how to check your system's capabilities.
-
* To install the necessary components, you need to be logged in as root user:
+
* To configure and install many components, you will need to have root privileges.  Commands that indicate root privileges are prefaced with "sudo".  (To add "sudo power" to your account, edit the /etc/sudoers file.  See "$ man sudoers")
-
*: <pre>sudo -i</pre>
+
* Command-line commands are prefaced with "$".  Do not enter $ when entering the commands in your terminal.
-
*: Give your password when prompted.
+
== Configuring distributions package manager ==
== Configuring distributions package manager ==
Line 19: Line 18:
===On Debian or Ubuntu===
===On Debian or Ubuntu===
-
# Add the following line to <code>/etc/apt/sources.list</code> file or create a <code>/etc/apt/sources.list.d/meego-sdk.list</code> file containing the following line:
+
# Add the following line to <code>/etc/apt/sources.list</code> file or create a <code>/etc/apt/sources.list.d/meego-sdk.list</code> file containing the following line.  Replace ${distribution}/${version} with one of the following values, depending on your Linux distribution: "debian/5.0", "ubuntu/09.10" or "ubuntu/10.04".
#: <pre>deb <nowiki>http://repo.meego.com/MeeGo/sdk/host/repos/${distribution}/${version}/</nowiki> /</pre>
#: <pre>deb <nowiki>http://repo.meego.com/MeeGo/sdk/host/repos/${distribution}/${version}/</nowiki> /</pre>
-
#: '''Note:''' replace ${distribution}/${version} pair with one of the following values, depending on your Linux distribution: "debian/5.0", "ubuntu/09.10" or "ubuntu/10.04".
+
#:  
# Add the repository public key:
# Add the repository public key:
#: <pre>$ sudo gpg --keyserver pgpkeys.mit.edu --recv 0BC7BEC479FC1F8A</pre>
#: <pre>$ sudo gpg --keyserver pgpkeys.mit.edu --recv 0BC7BEC479FC1F8A</pre>

Revision as of 23:34, 14 November 2010


This page instructs in setting up your MeeGo 1.1 development environment on Linux.

Contents

Prerequisites

  • To use the MeeGo SDK, you should be running a reasonably modern Linux distribution. Currently the MeeGo 1.1 SDK has been validated on Fedora 12, Fedora 13, Ubuntu 9.10, and Ubuntu 10.04 LTS. Other distributions such as openSUSE 11.x and Windows XP are planned for support soon. In addition, you should run on reasonably modern hardware, such as 32-bit Intel Atom or Intel Core 2 CPU.
  • If you intend to use QEMU, you will get reasonable performance only if your host system has VT support. See this page for details of how to check your system's capabilities.
  • To configure and install many components, you will need to have root privileges. Commands that indicate root privileges are prefaced with "sudo". (To add "sudo power" to your account, edit the /etc/sudoers file. See "$ man sudoers")
  • Command-line commands are prefaced with "$". Do not enter $ when entering the commands in your terminal.

Configuring distributions package manager

On Debian or Ubuntu

  1. Add the following line to /etc/apt/sources.list file or create a /etc/apt/sources.list.d/meego-sdk.list file containing the following line. Replace ${distribution}/${version} with one of the following values, depending on your Linux distribution: "debian/5.0", "ubuntu/09.10" or "ubuntu/10.04".
    deb http://repo.meego.com/MeeGo/sdk/host/repos/${distribution}/${version}/ /
  2. Add the repository public key:
    $ sudo gpg --keyserver pgpkeys.mit.edu --recv 0BC7BEC479FC1F8A
    $ sudo gpg --export --armor 0BC7BEC479FC1F8A | sudo apt-key add -
  3. Update packages database:
    $ sudo apt-get update
  4. Check that the MeeGo repository has been added to the file with, for example, the following command:
    $ sudo apt-cache policy madde
    If the repository has been successfully added, the command prints the details of the MADDE package.

On Fedora

  1. Go to the yum repository directory:
     # cd /etc/yum.repos.d/ 
  2. Add the MeeGo SDK yum repository:
     # wget http://repo.meego.com/MeeGo/sdk/host/repos/${distribution}/${version}/meego-sdk.repo
    Note: replace ${distribution}/${version} pair with one of the following values, depending on your Linux distribution: "fedora/12" or "fedora/13".
  3. Install the signing key:
     # rpm --import http://repo.meego.com/MeeGo/sdk/host/repos/${distribution}/${version}/repodata/repomd.xml.key 
  4. Update packages database:
    # yum update

On MeeGo

To add MeeGo repository, do one of the following:

  • Use the command:
zypper addrepo -f http://repo.meego.com/MeeGo/sdk/host/repos/${distribution}/${version}/meego-sdk.repo

Note: replace ${distribution}/${version} pair with one of the following values, depending on your Linux distribution: "meego/1.1" or "meego/trunk".

On openSUSE

To add MeeGo repository, do one of the following:

  • Use the command:
zypper addrepo -f http://repo.meego.com/MeeGo/sdk/host/repos/${distribution}/${version}/meego-sdk.repo

Note: replace ${distribution}/${version} pair with one of the following values, depending on your Linux distribution: "opensuse/11.2" or "opensuse/11.3".

Installing MeeGo SDK

  • Debian / Ubuntu
    $ sudo apt-get install meego-sdk
  • Fedora
    # yum install meego-sdk
  • OpenSUSE
    # zypper install meego-sdk

For ARM only:

  • Debian / Ubuntu
    $ sudo apt-get install meego-sdk-armv7l
  • Fedora
    # yum install meego-sdk-armv7l
  • OpenSUSE
    # zypper install meego-sdk-armv7l

For IA32 only:

  • Debian / Ubuntu
    $ sudo apt-get install meego-sdk-ia32
  • Fedora
    # yum install meego-sdk-ia32
  • OpenSUSE
    # zypper install meego-sdk-ia32

Creating and testing a target with MADDE

  1. Create MeeGo target in MADDE:
    $ sudo mad-admin create -f <target> 
    Where <target> is meego-core-armv7l-1.1 , meego-handset-ia32-1.1 or meego-netbook-ia32-1.1. Note that the -f flag instructs MADDE to download and install the appropriate sysroot tarball first.If you counter some problems,you can get a solution from http://wiki.meego.com/MeeGo_SDK_Troubleshooting#General_SDK_Errors
  2. To check that target and toolchain are found in MADDE:
    $ mad -t <target> pscreate -t qt-simple qthello
    $ cd qthello
    $ mad -t <target> qmake
    $ mad -t <target> make
    Where <target> is meego-core-armv7l-1.1 , meego-handset-ia32-1.1 or meego-netbook-ia32-1.1
  3. To check that the qt-simple application is created for the correct target, run:
    file build/qthello

MADDE can also be used to create runtimes (emulated MeeGo devices) for running and debugging applications. However, you are not required to create runtimes if you only intend to develop against real hardware running MeeGo.

Configuring Qt Creator to use the MeeGo toolchain(s)

Start Qt Creator by selecting Applications > Programming > Qt Creator.

Configure Qt Creator to use the MeeGo toolchain(s):

  1. Go to Tools > Options > Qt4 > Qt Versions.
  2. On the right side of the Qt Versions view, click on the plus sign button to add a new version.
    A blank, new version appears in the Qt Versions view.
  3. On the Version Name line, specify a name for the new version.
  4. On the qmake location line, specify a qmake location for the new version. The toolchain installs by default to usr/lib/madde/linux-i686/targets/<target>/bin/qmake.
  5. Click Rebuild, Apply and OK.
Adding the MeeGo toolchain(s) in Qt Creator

Developing with the SDK

To start developing with the MeeGo SDK, the hello world tutorial is a good starting point.

This tutorial covers how to start a project, package it, and deploy it to a device (either a real device, or a QEMU runtime set up through MADDE).

Removing components

On Ubuntu

To remove installed components, run:

$ sudo apt-get remove --purge meego-sdk-qtcreator
$ sudo apt-get remove --purge madde qt-tools
$ sudo apt-get remove --purge arm-2009q1
$ sudo apt-get remove --purge qemu-arm qemu-gl

To remove dependencies related to installed components, run:

$ sudo apt-get autoremove

To remove MADDE directory:

$ sudo rm -rf /usr/lib/madde

To remove the packages from your local repository (/var/cache/apt/archives/), run:

$ sudo apt-get clean

On openSUSE

To remove installed components, run:

# zypper remove -u meego-sdk-qt-creator
# zypper remove -u madde qt-tools
# zypper remove -u arm-2009q1
# zypper remove -u qemu-arm qemu-gl

To remove MADDE directory:

# rm -rf /usr/lib/madde
Personal tools