PUBLISHED
Introduction
This document provides information about how to manually create Tizen IVI images based on specific snapshot, including the following:
- Cloning Tizen source
- Preparing pre-builts binaries and build-config
- Building all packages by using GBS
- Creating images by using MIC
The snapshot below is taken as example throughout this document:
Cloning Tizen Source
Ensure the following before getting started:
- Gerrit account is available and ready for use.
- ~/.ssh/config is correctly configured, as shown below:
Host review.tizen.org Hostname review.tizen.org Port 29418 User <INPUT_YOUR_USER> # ProxyCommand connect -S <proxy:port> %h %p Host tizen Hostname review.tizen.org Port 29418 User <INPUT_YOUR_USER> # ProxyCommand connect -S <proxy:port> %h %p
For detailed instructions for account registration and configuration, refer to:
https://source.tizen.org/documentation/developer-guide/environment-setup
Assuming Tizen IVI source directory is ~/tizen_ivi_src, to clone Tizen source that corresponds to the snapshot below, execute the following commands:
$ mkdir ~/tizen_ivi_src & cd ~/tizen_ivi_src $ repo init -u tizen:scm/manifest -b tizen -m ivi.xml $ wget http://download.tizen.org/snapshots/tizen/ivi-3.0.m14.3/tizen-3.0.m14.3-ivi_20141028.3/builddata/manifest/tizen-3.0.m14.3-ivi_20141028.3_atom.xml -O .repo/manifests/ivi/projects.xml $ repo sync -j 32 # sync code
Preparing pre-builts Binaries and build-config
To prepare pre-built binaries, execute the following commands:
$ cd ~/tizen_ivi_src/pre-built/toolchain-x86 $ ./tools/update_prebuilt.py -L . -R http://download.tizen.org/snapshots/tizen/ivi-3.0.m14.3/tizen-3.0.m14.3-ivi_20141028.3/repos/atom/packages/
To prepare build config, execute the following commands:
$ curl http://download.tizen.org/snapshots/tizen/ivi-3.0.m14.3/tizen-3.0.m14.3-ivi_20141028.3/repos/atom/packages/repodata/bc9b8ccbcb19b264e227d3014602c230327434bd17a1f609cc052f1a9e62af0b-build.conf.gz|gunzip >~/tizen_ivi_src/scm/meta/build-config/build.conf
Building All Packages by Using GBS
Reviewing GBS Config
Upon successful repo sync, a default .gbs.conf that is sufficient for GBS local full build will be copied to the top directory under ~/tizen_ivi_src/.
Building All Packages
Once all Tizen source code is downloaded and gbs.conf is correctly configured, next step is to build all source by using GBS:
$ nohup gbs build -A i586 --threads=4 --baselibs >build.log 2>&1 & $ tail -f build.log
Upon successful local full build, the summary report can be seen in build.log file.
Creating Images by Using MIC
This section describes how to download and configure ks files, which then will be used to create images with MIC.
- For more detailed information, refer to:
- https://source.tizen.org/documentation/developer-guide/getting-started-guide/creating-tizen-images-mic
Downloading ks Files
- Download specific ks files from:
- http://download.tizen.org/snapshots/tizen/ivi-3.0.m14.3/tizen-3.0.m14.3-ivi_20141028.3/images/atom/
$ cd ~/tizen_ivi_src/ $ wget http://download.tizen.org/snapshots/tizen/ivi-3.0.m14.3/tizen-3.0.m14.3-ivi_20141028.3/images/atom/ivi-mbr-i586/tizen-3.0.m14.3-ivi_20141028.3_ivi-mbr-i586.ks
Updating ks Files
Update ks files based on the following diff content to remove remote repo and add local repo created by GBS and pre-builts repo:
-repo --name=ivi --baseurl=https://download.tizen.org/snapshots/tizen/ivi-3.0.m14.3/tizen-3.0.m14.3-ivi_20141028.3/repos/atom/packages/ +repo --name=local --baseurl=file:///$HOME/GBS-ROOT/local/repos/tizen3.0_ivi/i586 --priority=1 +repo --name=pre-built --baseurl=file:///$HOME/tizen_ivi_src/pre-built/toolchain-x86 --priority=2
Creating Tizen Images
To create Tizen images, execute the following commands:
$ cd ~/tizen_ivi_src/ $ time sudo mic cr auto tizen_20140703.2_ivi-mbr-i586.ks --tmpfs ... INFO: Running command: bzip2 -f /var/tmp/mic/build/imgcreate-gHJ3Dt/tmp-2jcC9E/tizen_20140703.2_ivi-mbr-i586-201407020958-sdb.raw INFO: Creating manifest file... INFO: The new image can be found here: /var/lib/jenkins/tizen/mic-output/tizen_20140703.2_ivi-mbr-i586-201407020958-sdb.bmap /var/lib/jenkins/tizen/mic-output/tizen_20140703.2_ivi-mbr-i586-201407020958-sdb.raw.bz2 /var/lib/jenkins/tizen/mic-output/tizen_20140703.2_ivi-mbr-i586-201407020958.xml /var/lib/jenkins/tizen/mic-output/manifest.json /var/lib/jenkins/tizen/mic-output/tizen_20140703.2_ivi-mbr-i586-201407020958-vmlinuz-3.14.2-1-x86-ivi INFO: Finished. real 4m5.028s user 3m28.720s sys 0m18.140s
At this point, the Tizen images based on specific snapshot has been successfully created and ready for use.