Open main menu

DAVE Developer's Wiki β

Changes

Building the Yocto BSP (XELK)

3,080 bytes added, 11:32, 26 November 2014
Created page with "{{InfoBoxTop}} {{AppliesToAxel}} {{AppliesToAxelLite}} {{Applies To Yocto}} {{InfoBoxBottom}} This is a quickstart guide to build Yocto BSP for Axel SOMs, to rebuild the bina..."
{{InfoBoxTop}}
{{AppliesToAxel}}
{{AppliesToAxelLite}}
{{Applies To Yocto}}
{{InfoBoxBottom}}

This is a quickstart guide to build Yocto BSP for Axel SOMs, to rebuild the binaries (u-boot, linux kernel, root file system) provided with XELK releases.

For more information regarding Yocto build system, go to its [[:Category:Yocto|dedicated category page]]

=== Build System prerequisite ===

Please read the [http://www.yoctoproject.org/docs/latest/mega-manual/mega-manual.html#getting-setup Yocto manual setup section] for a list of supported Linux distribution and their configuration.

DAVE Embedded System uses a standard Ubuntu 12.04.4 LTS Server 64 bit distribution plus the following additional packages:

<pre class="workstation-terminal">
$ sudo apt-get install gawk wget git-core diffstat unzip texinfo gcc-multilib \
build-essential chrpath socat libsdl1.2-dev xterm
</pre>

=== Build Axel Yocto BSP ===

Bora Yocto BSP uses [https://code.google.com/p/git-repo/ git-repo] tool to fetch all the required git repositories to build

<pre class="workstation-terminal">
dvdk@dvdk-vm:~/belk$ curl http://commondatastorage.googleapis.com/git-repo-downloads/repo > repo
dvdk@dvdk-vm:~/belk$ chmod a+x repo
dvdk@dvdk-vm:~/belk$ ./repo init -u git@git.dave.eu:dave/bora/axel-bsp.git -b axel
dvdk@dvdk-vm:~/belk$ ./repo sync
dvdk@dvdk-vm:~/belk$ source axel-bsp-init-env.sh build
dvdk@dvdk-vm:~/belk/build$ bitbake base-rootfs-image
</pre>

Please note that even the basic root file system requires a few hours to build on a mid-hi range desktop (4-6 cores, 8-12 GiB RAM) also depending on your Internet connection speed (all sources are fetched from the network). Nearly 20GiB of disk space is required for the build.

The resulting files (kernel, devicetree and u-boot binaries, plus .tar.gz root file system) will then be available inside ''build/tmp/deploy/images/axel''.

==== Build additional packages ====

To build additional packages the user must first enter the directory where the bora-bsp-init-env.sh is placed and source it

<pre class="workstation-terminal">
dvdk@dvdk-vm:~/xelk$ source bora-bsp-init-env.sh build
dvdk@dvdk-vm:~/xelk/build$
</pre>

And then can run any of the [[http://www.yoctoproject.org/docs/latest/mega-manual/mega-manual.html#usingpoky-components-bitbake bitbake]] command.

<pre class="workstation-terminal">
dvdk@dvdk-vm:~/xelk/build$ bitbake memtester
</pre>

The resulting packages (the default format is ipk) can be found inside ''build/tmp/deploy/ipk''.

<pre class="workstation-terminal">
dvdk@dvdk-vm:~/xelk/build$ ls -l tmp/deploy/ipk/armv7a-vfp-neon/memtester*
-rw-r--r-- 2 dvdk dvdk 7102 Aug 26 16:33 tmp/deploy/ipk/armv7a-vfp-neon/memtester_4.1.3-r0_armv7a-vfp-neon.ipk
-rw-r--r-- 2 dvdk dvdk 21720 Aug 26 16:33 tmp/deploy/ipk/armv7a-vfp-neon/memtester-dbg_4.1.3-r0_armv7a-vfp-neon.ipk
-rw-r--r-- 2 dvdk dvdk 792 Aug 26 16:33 tmp/deploy/ipk/armv7a-vfp-neon/memtester-dev_4.1.3-r0_armv7a-vfp-neon.ipk
-rw-r--r-- 2 dvdk dvdk 2748 Aug 26 16:33 tmp/deploy/ipk/armv7a-vfp-neon/memtester-doc_4.1.3-r0_armv7a-vfp-neon.ipk
</pre>