(→Overview) |
(→Linux) |
||
| (17 intermediate revisions not shown) | |||
| Line 1: | Line 1: | ||
== Overview == | == Overview == | ||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
| - | |||
| - | == Pre-requisites == | + | Problem statement: |
| - | * Install | + | * MeeGo SDK uses MADDE to manage multiple targets and developers are easy to switch between them. Basically a target includes 3 components: sysroot, runtime(qemu image) and toolchain. The toolchain is rarely changed during the development of a major MeeGo release like 1.1 or 1.2. For sysroot and runtime, they change daily since MeeGo release team creates daily build for different MeeGo profiles like Handset, Netbook, IVI and so on. |
| - | * Download the meego-sdk-update-target | + | * By default, the installation of MeeGo SDK will include several targets which are created together with the major MeeGo release. But if developers want to keep tracking the latest MeeGo status, they have to manually add latest target like daily sysroot/runtime into MeeGo SDK. Adding a new target is not straightforward and not easy for developer to do. |
| + | |||
| + | This wiki page introduces a tool to easily add new targets into MeeGo SDK. | ||
| + | |||
| + | == Pre-requisites == | ||
| + | === Linux === | ||
| + | * Install [[SDK/Docs/1.1/Getting_started_with_the_MeeGo_SDK_for_Linux | MeeGo SDK for Linux]] | ||
| + | * Download the [http://download3.meego.com/meego-sdk-update-target meego-sdk-update-target] tool | ||
| + | ** You can get the latest version of meego-sdk-update-target from http://meego.gitorious.org/meego-developer-tools/meego-sdk-update-target. | ||
| + | * Put the meego-sdk-update-target to /usr/bin | ||
| + | |||
| + | === Windows === | ||
| + | * Install [[SDK/Docs/1.1/Getting_started_with_the_MeeGo_SDK_for_Windows | MeeGo SDK for Windows]] | ||
| + | * Open Madde Terminal | ||
| + | * Put the meego-sdk-update-target to /bin | ||
| + | * Download the meego-sdk-update-target inside the terminal by running following command. Be sure you have correct proxy. | ||
| + | /madbin/curl.exe http://download3.meego.com/meego-sdk-update-target -o /bin/meego-sdk-update-target | ||
| + | * Note: On windows, all commands are ran inside the Madde Terminal and you don't need "sudo" in following sections. | ||
== Usage and examples == | == Usage and examples == | ||
* Get help | * Get help | ||
| - | + | $ ./meego-sdk-update-target | |
| - | + | ||
| - | + | * There are some options set with default value if they are not specified on command line. You can change them for your convenience. | |
| - | + | * The tool only supports Handset and Netbook as targets at this stage. | |
| - | + | * The tool is a shell script and free to change for your convenience. | |
| - | + | ||
* To update with a new Handset MeeGo trunk build 1.1.80.13.20110104.1 from http://repo.meego.com/MeeGo/builds/trunk/ | * To update with a new Handset MeeGo trunk build 1.1.80.13.20110104.1 from http://repo.meego.com/MeeGo/builds/trunk/ | ||
| - | + | $ sudo meego-sdk-update-target -u 1.1.80.13.20110104.1 -url http://repo.meego.com/MeeGo/builds/trunk | |
| - | + | ||
| - | + | ||
* To update with a new Netbook MeeGo trunk-daily build trunk-daily-1.1.80.12.20101223.1 from http://download.meego.com/trunk-daily/builds/1.1.80 | * To update with a new Netbook MeeGo trunk-daily build trunk-daily-1.1.80.12.20101223.1 from http://download.meego.com/trunk-daily/builds/1.1.80 | ||
| - | + | $ sudo meego-sdk-update-target -d netbook -u trunk-daily-1.1.80.12.20101223.1 -url http://download.meego.com/trunk-daily/builds/1.1.80 | |
| - | + | ||
| - | + | ||
* To update with a new Handset MeeGo testing-daily build testing-daily-1.1.80.13.20110104.1 from http://download.meego.com/testing-daily/builds/1.1.80 | * To update with a new Handset MeeGo testing-daily build testing-daily-1.1.80.13.20110104.1 from http://download.meego.com/testing-daily/builds/1.1.80 | ||
| - | + | $ sudo meego-sdk-update-target -d handset -u testing-daily-1.1.80.13.20110104.1 -url http://download.meego.com/testing-daily/builds/1.1.80 | |
| - | + | ||
| - | + | * To update with a new Handset MeeGo target with specific sysroot and runtime tarball files, you need to provide a name of the target with "-u" option | |
| - | * To update with a new Handset MeeGo target with specific sysroot and runtime tarball files, you need to provide a name of the target with "-u" option | + | $ sudo meego-sdk-update-target -u my-target -sysroot url_to_sysroot_tar.gz -runtime url_to_runtime_tar.bz2 |
| - | + | ||
| - | + | * To update with a new Handset MeeGo target for ARM with specific sysroot file, you need to provide a name of the target with "-u" option | |
| - | + | $ sudo meego-sdk-update-target -u my-target -a armv7l -sysroot url_to_armv7l_sysroot_tar.gz | |
| + | |||
| + | * You can use the following commands to update the targets to MeeGo SDK 1.1.2 | ||
| + | $ sudo ./meego-sdk-update-target -u 1.1.2 -sysroot http://download3.meego.com/meego-core-armv7l-madde-sysroot-1.1.2-fs.tar.bz2 | ||
| + | |||
| + | $ sudo ./meego-sdk-update-target -u 1.1.2 -sysroot http://download3.meego.com/meego-handset-ia32-madde-sysroot-1.1.20110106.1204-fs.tar.gz -runtime http://download3.meego.com/meego-handset-ia32-qemu-1.1.20110110.1026-raw.tar.bz2 | ||
| + | |||
| + | $ sudo ./meego-sdk-update-target -u 1.1.2 -d netbook -sysroot http://download3.meego.com/meego-core-ia32-madde-sysroot-1.1.20110106.1139-fs.tar.gz -runtime http://download3.meego.com/meego-netbook-ia32-qemu-1.1.20110110.1049-raw.tar.bz2 | ||
| + | |||
| + | $ sudo ./meego-sdk-update-target -u 1.1.2 -a armv7l -sysroot http://download3.meego.com/meego-core-armv7l-madde-sysroot-1.1.2-fs.tar.bz2 | ||
| + | |||
== Create your own target (sysroot and runtime) == | == Create your own target (sysroot and runtime) == | ||
| - | * The sysroot has to be a tar.gz or tar.bz2 and can be generated by adding | + | |
| - | + | * The sysroot has to be a tar.gz or tar.bz2 and can be generated by adding following command parameters to mic2 | |
| - | + | $ sudo mic-image-creator --format=fs --package=tar.gz ... | |
| - | + | ||
| - | * The runtime has to be a tar.gz or tar.bz2 and can be generated by adding following | + | * The runtime has to be a tar.gz or tar.bz2 and can be generated by adding following command parameters to mic2 |
| - | + | $ sudo mic-image-creator --format=raw --package=tar.bz2 --release=release_no --compress-disk-image=none ... | |
| - | + | ||
| - | + | * Please check help of mic-image-creator for detailed explanation of those options | |
| - | * Please check help of mic-image-creator for detailed explanation of those options | + | $ sudo mic-image-creator --help |
| - | + | ||
| - | + | ||
| - | + | ||
* You can find the ks file to create MeeGo sysroot and runtime at http://meego.gitorious.org/meego-os-base/image-configurations/trees/master/. | * You can find the ks file to create MeeGo sysroot and runtime at http://meego.gitorious.org/meego-os-base/image-configurations/trees/master/. | ||
| + | |||
| + | == Other Notes == | ||
| + | |||
| + | * The script will add a new target, which need several GB disk space (>5GB). Please make sure you have enough disk space. | ||
| + | * It's better to remove some old target which is not useful. To get the target name and the runtime name, you could run: | ||
| + | $ sudo mad-admin list | ||
| + | |||
| + | and then run following commands to remove it: | ||
| + | $ sudo mad-admin remove '''<target name>''' | ||
| + | $ sudo mad-admin remove '''<runtime name>''' | ||
| + | |||
| + | But using above 2 commands will not totally remove the cached and already generated files for the target. To remove all of them to save disk space, you need to remove the related folder and files: | ||
| + | |||
| + | $ sudo rm -rf /usr/lib/madde/linux-'''<host arch>'''/targets/'''<target name>''' | ||
| + | $ sudo rm -rf /usr/lib/madde/linux-'''<host arch>'''/runtimes/'''<runtime name>''' | ||
| + | $ sudo rm -rf /usr/lib/madde/linux-'''<host arch>'''/sysroots/'''<sysroot name>''' | ||
| + | $ sudo rm -rf /usr/lib/madde/linux-'''<host arch>'''/tools/'''<runtime name>''' | ||
| + | $ sudo rm -f /usr/lib/madde/linux-'''<host arch>'''/cache/'''<tarball name>''' | ||
| + | |||
| + | Note: replace '''<host arch>''' with one of the following values "i686" or "x86_64". | ||
[[Category:Tutorial]] | [[Category:Tutorial]] | ||
Contents |
Problem statement:
This wiki page introduces a tool to easily add new targets into MeeGo SDK.
/madbin/curl.exe http://download3.meego.com/meego-sdk-update-target -o /bin/meego-sdk-update-target
$ ./meego-sdk-update-target
$ sudo meego-sdk-update-target -u 1.1.80.13.20110104.1 -url http://repo.meego.com/MeeGo/builds/trunk
$ sudo meego-sdk-update-target -d netbook -u trunk-daily-1.1.80.12.20101223.1 -url http://download.meego.com/trunk-daily/builds/1.1.80
$ sudo meego-sdk-update-target -d handset -u testing-daily-1.1.80.13.20110104.1 -url http://download.meego.com/testing-daily/builds/1.1.80
$ sudo meego-sdk-update-target -u my-target -sysroot url_to_sysroot_tar.gz -runtime url_to_runtime_tar.bz2
$ sudo meego-sdk-update-target -u my-target -a armv7l -sysroot url_to_armv7l_sysroot_tar.gz
$ sudo ./meego-sdk-update-target -u 1.1.2 -sysroot http://download3.meego.com/meego-core-armv7l-madde-sysroot-1.1.2-fs.tar.bz2
$ sudo ./meego-sdk-update-target -u 1.1.2 -sysroot http://download3.meego.com/meego-handset-ia32-madde-sysroot-1.1.20110106.1204-fs.tar.gz -runtime http://download3.meego.com/meego-handset-ia32-qemu-1.1.20110110.1026-raw.tar.bz2
$ sudo ./meego-sdk-update-target -u 1.1.2 -d netbook -sysroot http://download3.meego.com/meego-core-ia32-madde-sysroot-1.1.20110106.1139-fs.tar.gz -runtime http://download3.meego.com/meego-netbook-ia32-qemu-1.1.20110110.1049-raw.tar.bz2
$ sudo ./meego-sdk-update-target -u 1.1.2 -a armv7l -sysroot http://download3.meego.com/meego-core-armv7l-madde-sysroot-1.1.2-fs.tar.bz2
$ sudo mic-image-creator --format=fs --package=tar.gz ...
$ sudo mic-image-creator --format=raw --package=tar.bz2 --release=release_no --compress-disk-image=none ...
$ sudo mic-image-creator --help
$ sudo mad-admin list
and then run following commands to remove it:
$ sudo mad-admin remove <target name> $ sudo mad-admin remove <runtime name>
But using above 2 commands will not totally remove the cached and already generated files for the target. To remove all of them to save disk space, you need to remove the related folder and files:
$ sudo rm -rf /usr/lib/madde/linux-<host arch>/targets/<target name> $ sudo rm -rf /usr/lib/madde/linux-<host arch>/runtimes/<runtime name> $ sudo rm -rf /usr/lib/madde/linux-<host arch>/sysroots/<sysroot name> $ sudo rm -rf /usr/lib/madde/linux-<host arch>/tools/<runtime name> $ sudo rm -f /usr/lib/madde/linux-<host arch>/cache/<tarball name>
Note: replace <host arch> with one of the following values "i686" or "x86_64".