Unterschiede

Hier werden die Unterschiede zwischen zwei Versionen angezeigt.

Link zu dieser Vergleichsansicht

Nächste Überarbeitung
Vorhergehende Überarbeitung
Nächste ÜberarbeitungBeide Seiten der Revision
software:linux:toradex:toradex-build [2019-10-14 13:05] – angelegt mlammerichsoftware:linux:toradex:toradex-build [2021-03-01 09:43] Moritz Lammerich
Zeile 1: Zeile 1:
 ====== Building a New Image ====== ====== Building a New Image ======
  
-Images are built using bitbake and yocto.+Images are built using [[ :software/linux/yocto/start | the yocto project]].
  
 The build process is based on [[ https://developer.toradex.com/knowledge-base/board-support-package/openembedded-%28core%29#update-to-a-specific-version-by-using-its-tag | this toradex guide ]]. The build process is based on [[ https://developer.toradex.com/knowledge-base/board-support-package/openembedded-%28core%29#update-to-a-specific-version-by-using-its-tag | this toradex guide ]].
  
-==== Customising the Toradex image ====+===== Setting up the build environment =====
  
-coming soon+The following was taken from [[ https://developer.toradex.com/knowledge-base/board-support-package/openembedded-%28core%29#update-to-a-specific-version-by-using-its-tag | the toradex guide ]].
  
 +First, make sure that the ''repo'' tool is available:
  
-==== Building the SDK ====+<code> 
 +mkdir ~/bin 
 +export PATH=~/bin:$PATH 
 +curl http://commondatastorage.googleapis.com/git-repo-downloads/repo > ~/bin/repo 
 +chmod a+x ~/bin/repo 
 +</code> 
 + 
 +Next, make sure ''git'' is installed and configured: 
 + 
 +<code> 
 +sudo apt install git 
 +git config --global user.name "John Doe" 
 +git config --global user.email johndoe@example.com 
 +</code> 
 + 
 +Now fetch the toradex layers using ''repo'': 
 + 
 +<code> 
 +mkdir ${HOME}/oe-core 
 +cd ${HOME}/oe-core 
 +repo init -u https://git.toradex.com/toradex-manifest.git -b refs/tags/5.1.0 -m tdxref/default.xml 
 +repo sync 
 +</code> 
 + 
 +Finally, source the setup script: 
 + 
 +<code> 
 +. export 
 +</code> 
 + 
 +==== Adding the NTB layers ==== 
 + 
 +The NTB specific recipes are maintained in the [[ software:linux:yocto:meta-ntb | meta-ntb]] layer. 
 + 
 +change into the ''layers'' directory: 
 + 
 +<code> 
 +cd ../layers 
 +</code> 
 + 
 +clone the [[ https://github.com/zechenturm/meta-ntb | meta-ntb ]] repository: 
 + 
 +<code> 
 +git clone https://github.com/zechenturm/meta-ntb 
 +</code> 
 + 
 +change back to the ''build'' directory and add the layers to ''conf/bblayers.conf'': 
 + 
 +<code> 
 +cd ../build 
 +nano conf/bblayers.conf 
 +</code> 
 + 
 +<code> 
 +BBLAYERS ?= " \ 
 +... 
 +${TOPDIR}/../layers/meta-ntb/meta-ntb \ 
 +${TOPDIR}/../layers/meta-ntb/meta-ntb-toradex \ 
 +
 +</code> 
 + 
 +==== local.conf ===== 
 + 
 +Add the following to ''conf/local.conf'' 
 + 
 +<code> 
 +MACHINE = "cb20" 
 +</code> 
 + 
 +==== build ==== 
 + 
 +Production Image: 
 + 
 +<code> 
 +bitbake ntb-image 
 +</code> 
 + 
 +Development Image: 
 + 
 +To create a development image, add the following to ''local.conf''
 + 
 +<code> 
 +NTB_DEVBUILD = "1" 
 +</code> 
 + 
 +Then build the image: 
 + 
 +<code> 
 +bitbake ntb-image 
 +</code>
  
-The Linux SDK can be built using yocto. Check the [[ https://developer.toradex.com/knowledge-base/linux-sdks | Toradex guide ]] for more information