Difference between revisions of "Building the Yocto BSP (BELK/BXELK)"

From DAVE Developer's Wiki
Jump to: navigation, search
(Created page with "{{InfoBoxTop}} {{Applies To Bora}} {{Applies To BoraX}} {{InfoBoxBottom}} {{ImportantMessage|text=As the structure of the BELK/BXELK is based on several tools, it is strongly...")
 
(Replaced content with "{{WorkInProgress}}")
Line 1: Line 1:
{{InfoBoxTop}}
+
{{WorkInProgress}}
{{Applies To Bora}}
 
{{Applies To BoraX}}
 
{{InfoBoxBottom}}
 
{{ImportantMessage|text=As the structure of the BELK/BXELK is based on several tools, it is strongly recommended the reading of [[Logical_structure_of_Bora_and_BoraX_Embedded_Linux_Kits_(BELK/BXELK)|this document]] first.
 
}}
 
 
 
==Introduction==
 
As known, Linux needs a root file system to operate: a root file system must contain everything needed to support the Linux system (applications, settings, data, ..). The root file system is the file system that is contained on the same partition on which the root directory is located. The Linux kernel, at the end of its startup stage, mounts the root file system on the configured root device and finally launches the <code>/sbin/init</code>, the first user space process and "father" of all the other processes.
 
For more information on the Linux filesystem, please refer to http://www.thegeekstuff.com/2010/09/linux-file-system-structure/.
 
 
 
BELK/BXELK provides one (or more) pre-built root file system, that can be used during the evaluation/development phase since it provides a relatively rich set of packages for working with the BORA platform. This root file system is located here: <code>/home/dvdk/<target_name>/rfs/<kit_name></code>.
 
 
 
BELK/BXELK also provides a rich repository containing pre-built applications and libraries. These packages can be easily installed on the target by using the <code>smart</code> tool. Please refer to [[Advanced_use_of_Yocto_build_system_(BELK/BXELK)#Using_pre-built_package_archive|this section]] for more details.
 
 
 
==How to build the Yocto BSP images including the U-Boot binary file, the Linux kernel image, and the target root file system image==
 
{{ImportantMessage|text=The following procedure requires the access to the DAVE Embedded Systems' git repositories. The access to such repositories is granted to development kit's owners only. Please refer to [[Accessing_DAVE_Embedded_Systems_restricted_git_repositories|this page]] for detailed instructions on how to get it.}}
 
 
 
The generic procedure to generate the Yocto BSP image is the following:
 
<pre class="board-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:bora/bora-bsp.git -b bora-morty
 
dvdk@dvdk-vm:~/belk$ ./repo sync
 
dvdk@dvdk-vm:~/belk$ source bora-bsp-init-env.sh
 
dvdk@dvdk-vm:~/belk/build$ bitbake <target-image-name>
 
</pre>
 
bora-image
 
bora-image-devel
 
bora-image-networking
 
 
 
The components listed in the table above can be kept in sync and up to date with DAVE Embedded Systems' repositories.
 
Once the git account has been enabled, the developer can:
 
*clone the repository with the <code>git clone <git_remote_repository></code> command
 
*synchronize a source tree entering the repository directory and launching the <code>git fetch origin</code> command.
 
Please note that git fetch doesn't merge the commits on the current branch. To do that, the developer should run the <code>git merge</code> command or replace the ''fetch-merge'' process with a single <code>git pull</code> command. Please note that the recommended method is the ''fetch-merge'' process. For further information on Git, please refer to the official Git Documentation (http://git-scm.com/documentation).
 
 
 
{{ImportantMessage|text=Technically speaking, the developer can run a Yocto-based full build process to (re)generate all the pre-built objects included in the MVM. However, this process requires a lot of hardware resources in terms of disk storage, RAM, and processing power. For this reason, it is discouraged to use the MVM to perform such build. Using a physical machine is recommended instead. For more details on this, please refer to [[Advanced_use_of_Yocto_build_system_(BELK/BXELK)|this page]].
 
}}
 
 
 
 
 
 
 
The following table lists the pre-built root file systems included in the MVM.
 
{| class="wikitable" border="1"
 
!Kit version<br>BELK<br>BXELK
 
!Image name
 
!Build commands
 
!Path
 
|-
 
|rowspan="3"|<br>4.0.0<br>2.0.0
 
|<code>bora-image</code>
 
|<pre>
 
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:bora/bora-bsp.git -b bora-morty
 
dvdk@dvdk-vm:~/belk$ ./repo sync
 
dvdk@dvdk-vm:~/belk$ source bora-bsp-init-env.sh
 
dvdk@dvdk-vm:~/belk/build$ bitbake bora-image
 
</pre>
 
|<code>/home/dvdk/bora/rfs/belk-4.0.0</code>
 
|-
 
|<code>bora-image-devel</code>
 
|<pre>
 
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:bora/bora-bsp.git -b bora-morty
 
dvdk@dvdk-vm:~/belk$ ./repo sync
 
dvdk@dvdk-vm:~/belk$ source bora-bsp-init-env.sh
 
dvdk@dvdk-vm:~/belk/build$ bitbake bora-image-devel
 
</pre>
 
|<code>/home/dvdk/bora/rfs/belk-4.0.0</code>
 
|-
 
|<code>bora-image-networking</code>
 
|<pre>
 
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:bora/bora-bsp.git -b bora-morty
 
dvdk@dvdk-vm:~/belk$ ./repo sync
 
dvdk@dvdk-vm:~/belk$ source bora-bsp-init-env.sh
 
dvdk@dvdk-vm:~/belk/build$ bitbake bora-image-networking
 
</pre>
 
|<code>/home/dvdk/bora/rfs/belk-4.0.0</code>
 
|-
 
|}
 
 
 
 
 
The following table lists the pre-built Yocto SDKs included in the MVM. These SDKs are associated with the root file system images mentioned above.
 
{| class="wikitable" border="1"
 
!Kit version<br>BELK<br>BXELK
 
!SDK name
 
!Build commands
 
!Path
 
|-
 
|rowspan="3"|<br>4.0.0<br>2.0.0
 
|<code>bora-image</code>
 
|<pre>
 
bitbake bora-image -c populate-sdk
 
</pre>
 
|<code>/home/dvdk/bora/sdk/belk-4.0.0/sysroots/cortexa9hf-neon-xilinx-linux-gnueabi</code>
 
|-
 
|<code>bora-image-devel</code>
 
|<pre>
 
bitbake bora-image-devel -c populate-sdk
 
</pre>
 
|<code>/home/dvdk/bora/sdk/belk-4.0.0/sysroots/cortexa9hf-neon-xilinx-linux-gnueabi</code>
 
|-
 
|<code>bora-image-networking</code>
 
|<pre>
 
bitbake bora-image-networking -c populate-sdk
 
</pre>
 
|<code>/home/dvdk/bora/sdk/belk-4.0.0/sysroots/cortexa9hf-neon-xilinx-linux-gnueabi</code>
 
|-
 
|}
 
 
 
 
 
About C/C++ application development and debugging, please refer to [[Debugging_with_Eclipse_(MVM)|this page]].
 

Revision as of 16:28, 11 September 2017

WorkInProgress.gif