diff options
| author | Manuel Traut <manut@linutronix.de> | 2016-01-22 16:19:44 +0100 |
|---|---|---|
| committer | Manuel Traut <manut@linutronix.de> | 2016-01-22 16:19:44 +0100 |
| commit | 6a9ecaaa0057af202394d68fd844751086c7f92a (patch) | |
| tree | fdf2d478cb756198da69a7f281fc55e1c5138771 /distribution | |
| parent | f9ca79e5fc2c100aca5ab16628677a92aa57f566 (diff) | |
rework yocto advanced slides
- improve ordering
- add examples
Signed-off-by: Manuel Traut <manut@linutronix.de>
Diffstat (limited to 'distribution')
| -rw-r--r-- | distribution/yocto-advanced/pres_yocto-advanced.tex | 694 |
1 files changed, 303 insertions, 391 deletions
diff --git a/distribution/yocto-advanced/pres_yocto-advanced.tex b/distribution/yocto-advanced/pres_yocto-advanced.tex index e111aa8..1a2b644 100644 --- a/distribution/yocto-advanced/pres_yocto-advanced.tex +++ b/distribution/yocto-advanced/pres_yocto-advanced.tex @@ -6,12 +6,11 @@ \begin{frame} \frametitle{Agenda} \begin{itemize} -\item Using BSP layers -\item Build a predefined image -\item Creating a layer -\item Define a distribution -\item Create an image -\item Writing recipes + \item Using BSP layers + \item Create layers \& recipes for own applications + \item Define a distribution + \item Create a customized image class + \item Build images \end{itemize} \end{frame} @@ -42,24 +41,18 @@ meta-mylayer \begin{itemize} \item add conf and class directories to BBPATH \begin{verbatim}BBPATH =. "${LAYERDIR}"\end{verbatim} - \pause \item add recipe directories to BBFILES \begin{verbatim}BBFILES += "${LAYERDIR}/recipes-*/*/*.bb \ ${LAYERDIR}/recipes-*/*/*.bbappend"\end{verbatim} - \pause \item add layer name to BBFILE\_COLLECTIONS \begin{verbatim}BBFILE_COLLECTIONS += "mylayer"\end{verbatim} - \pause \item set root of the layer \begin{verbatim}BBFILE_PATTERN_mylayer = "^${LAYERDIR}/"\end{verbatim} - \pause \item set default priority of the layer \begin{verbatim}BBFILE_PRIORITY_mylayer = "5"\end{verbatim} - \pause \item set version of layer (only increment if dependencies with other layers are affected) \begin{verbatim}LAYERVERSION_mylayer = "2"\end{verbatim} - \pause \item set dependencies to other layers \begin{verbatim}LAYERDEPENDS_mylayer = "meta-yocto"\end{verbatim} \end{itemize} @@ -70,17 +63,12 @@ meta-mylayer is useful to debug relations between different layers, options are: \begin{description} \item [show-layers] shows the current configured layers - \pause \item [show-recipes] lists available recipes and the layers that provide them. - \pause \item [show-overlayed] lists overlayed recipes - \pause \item [show-appends] lists .bbappend files and the recipe files to which they apply - \pause \item [show-cross-depends] lists dependency relationships between recipes that cross layer boundaries - \pause \item [flatten] flattens the layer configuration into a separate output directory. \end{description} @@ -91,7 +79,6 @@ is useful to debug relations between different layers, options are: \begin{itemize} \item It is possible for a recipe with a lower version number PV in a layer that has a higher priority to take precedence. - \pause \item Also, the layer priority does not currently affect the precedence order of .conf or .bbclass files. Future versions of BitBake might address this. \end{itemize} @@ -102,27 +89,22 @@ order of .conf or .bbclass files. Future versions of BitBake might address this. retrive the layer from your BSP/SoC vendor \begin{verbatim} poky % git clone git://git.yoctoproject.org/meta-ti -poky % git branch -r -poky % git checkout <RELEASE> +poky % cd meta-ti +poky/meta-ti % git branch -r +poky/meta-ti % git checkout -t origin/fido -b fido +poky/meta-ti % cd .. +poky % git checkout -t origin/fido -b fido \end{verbatim} - \pause +\end{frame} + +\begin{frame}[fragile] +\frametitle{layer dependencies} have a look at it's dependencies \begin{verbatim} poky % cat meta-ti/conf/layer.conf | grep LAYERDEPENDS -LAYERDEPENDS_ti = "core" \end{verbatim} - \pause -and retrieve them also -\begin{verbatim} -poky % git clone -b daisy git://git.yoctoproject.org/meta-fsl-arm -\end{verbatim} - \pause -check dependencies again -\begin{verbatim} -poky % git clone /home/devel/yocto/meta-mini -\end{verbatim} - \pause -\dots no more dependencies?! \dots OK - finished. +no dependencies, so we are safe to continue, otherwise +retrive more layers. \end{frame} \begin{frame}[fragile] @@ -133,13 +115,13 @@ poky/build-ti % \end{verbatim} \end{frame} -\subsection{Build a predefined image} +\subsection{configure build environment} \begin{frame} \frametitle{overview} builds are configured using two configuration files \begin{itemize} - \item build-ti/conf/bblayers.conf - \item build-ti/conf/local.conf + \item /home/devel/poky/build-ti/conf/bblayers.conf + \item /home/devel/poky/build-ti/conf/local.conf \end{itemize} \end{frame} @@ -165,7 +147,7 @@ meta-yocto-bsp /home/devel/poky/meta-yocto-bsp 5 \end{frame} \begin{frame}[fragile] -\frametitle{add ti layers} +\frametitle{add ti and meta-mini layers} modify the BBLAYERS variable in bblayers.conf \begin{verbatim} BBLAYERS ?= " \ @@ -183,7 +165,7 @@ layer path priority meta /home/devel/poky/meta 5 meta-yocto /home/devel/poky/meta-yocto 5 meta-yocto-bsp /home/devel/poky/meta-yocto-bsp 5 -meta-ti /home/devel/poky/meta-ti 5 +meta-ti /home/devel/poky/meta-ti 6 \end{verbatim} \end{frame} @@ -195,97 +177,30 @@ poky/build-ti % bitbake-layers show-overlayed Parsing recipes..done. === Overlayed recipes === directfb: - meta 1.7.1 meta-ti 1.6.3 + meta 1.7.1 directfb-examples: - meta 1.7.0 meta-ti 1.6.0 + meta 1.7.0 xserver-xorg: - meta 2:1.15.0 meta-ti 2:1.14.4 + meta 2:1.15.0 \end{verbatim} \end{frame} -\begin{frame} -\frametitle{local.conf} -is used to configure -\begin{itemize} - \item the target machine - \pause - \item paths - \pause - \item the used distribution - \pause - \item package formats - \pause - \item arch of developer machine - \pause - \item additional image features - \pause - \item use additional classes - \pause - \item enable testing - \pause - \item devshell terminal - \pause - \item patch resolver - \pause - \item disk monitoring - \pause - \item sstate mirrors - \pause - \item qemu configuration - \pause - \item incompatible licenses, e.g. INCOMPATIBLE\_LICENSE = “GPLv3” -\end{itemize} -\end{frame} - -\begin{frame}[fragile] -\frametitle{configure the machine} -to get a list of currently available machines configs: -\begin{verbatim} -poky/build-ti % grep -r '@NAME' ../meta*/conf/machine -\end{verbatim} -beaglebone.conf - seems to be the one for our bord, so set -imx6qsabrelite.conf - seems to be the one for our bord, so set -\begin{verbatim} -MACHINE ??= "beaglebone" -\end{verbatim} -in conf/local.conf -\end{frame} - -\begin{frame}[fragile] -\frametitle{package format} -as we realized with toaster, rpm packaging consumes a lot of CPU time, so lets -try ipk, by setting -\begin{verbatim} -PACKAGE_CLASSES ?= "package_ipk" -\end{verbatim} -in conf/local.conf -\end{frame} - -\begin{frame}[fragile] -\frametitle{set extra image features} -we want an image suitable for development, so set -\begin{verbatim} -EXTRA_IMAGE_FEATURES = "debug-tweaks tools-debug \ - eclipse-debug tools-profile" -\end{verbatim} -in conf/local.conf -\end{frame} - \begin{frame}[fragile] -\frametitle{build an predefined image} +\frametitle{EXCURSUS: build an imx.6 image \#1} use \begin{verbatim} ls ../*/*/images/ \end{verbatim} -to get a list of predefined images; however none of them fits my needs\dots +to get a list of predefined images; image, you want to build an imx6 image, so +none of them fits your needs\dots \pause \begin{verbatim} poky/build-fsl % cd .. -poky % git clone -b daisy https://github.com/Freescale/meta-fsl-demos.git -poky % git clone -b daisy git://git.openembedded.org/meta-openembedded +poky % git clone -b fido https://github.com/Freescale/meta-fsl-demos.git +poky % git clone -b fido git://git.openembedded.org/meta-openembedded poky % cd - \end{verbatim} \pause @@ -304,16 +219,16 @@ BBLAYERS ?= " \ \end{frame} \begin{frame}[fragile] -\frametitle{build a qt demo image} +\frametitle{EXCURSUS: build an imx.6 image \#2} +build a qt demo image \begin{verbatim} -poky/build-ti % source toaster start -poky/build-ti % bitbake qt4e-demo-image +poky/build-imx6 % bitbake qt4e-demo-image Currently 4 running tasks (26 of 4459): \end{verbatim} \end{frame} \begin{frame}[fragile] -\frametitle{build a ti demo image} +\frametitle{EXCURSUS: build an imx.6 image \#3} \dots back from coffee break \begin{verbatim} ERROR: No new tasks can be executed since @@ -322,18 +237,18 @@ ERROR: No new tasks can be executed since what happened?? \pause \begin{verbatim} -poky/build-ti % df -h +poky/build-imx6 % df -h Filesystem Size Used Avail Use% Mounted on /dev/sda4 367G 348G 850M 100% / -poky/build-ti % du -sm . +poky/build-imx6 % du -sm . 31026 . -poky/build-ti % du -sm ../build +poky/build-imx6 % du -sm ../build 29172 ../build/ \end{verbatim} \pause \dots so the solution is to cleanup the disk and run \begin{verbatim} -poky/build-ti % bitbake qt4e-demo-image +poky/build-imx6 % bitbake qt4e-demo-image \end{verbatim} again. @@ -341,7 +256,8 @@ A different behaviour can be configured in 'conf/local.conf'. \end{frame} \begin{frame}[fragile] -\frametitle{example of an issue with a sabrelite board} +\frametitle{EXCURSUS: build an imx.6 image \#4} +example of an issue with a sabrelite board \begin{verbatim} ERROR: To use 'gpu-viv-bin-mx6q' you need to accept the Freescale EULA @@ -373,8 +289,7 @@ again. \end{frame} \begin{frame}[fragile] -\frametitle{flashing the image} -if the build is completed the image can be transfered to a sdcard: +\frametitle{EXCURSUS: flash the official beaglebone image \#1} \begin{verbatim} poky/build-ti % sudo fdisk /dev/mmcblk0 # create a @@ -387,7 +302,7 @@ poky/build-ti % sudo fdisk /dev/mmcblk0 \end{frame} \begin{frame}[fragile] -\frametitle{flashing the image \#2} +\frametitle{EXCURSUS: flash the official beaglebone image \#2} \begin{verbatim} poky/build-ti % sudo mkfs.vfat -F 16 -n boot /dev/mmcblk0p1 poky/build-ti % sudo mke2fs -j -L "root" /dev/mmcblk0p2 @@ -431,268 +346,12 @@ poky/meta-mini % git commit -sam 'inital version' \end{frame} \begin{frame}[fragile] +\frametitle{machine configs} +to get a list of currently available machine configs: \begin{verbatim} -poky/meta-mini % cd ../build-ti -\end{verbatim} -edit 'conf/bblayers.conf': -\begin{verbatim} -BBLAYERS ?= " \ - /home/devel/poky/meta \ - /home/devel/poky/meta-yocto \ - /home/devel/poky/meta-yocto-bsp \ - /home/devel/poky/meta-ti \ - /home/devel/poky/meta-mini \ - " -\end{verbatim} -\end{frame} - -\subsection{Define a distribution} -\begin{frame} -\frametitle{why define a distribution?} -\begin{itemize} -\item naming of the toolchain (codenames, vendor) - \pause -\item version numbers - \pause -\item enable default features -\end{itemize} -\end{frame} - -\begin{frame} -\frametitle{distro features: file-systems} -\begin{description} -\item[cramfs] CramFS support - \pause -\item[ext2] tools for supporting for devices with internal HDD/Microdrive - for storing files (instead of Flash only devices) - \pause -\item[nfs] NFS client support (for mounting NFS exports on device) - \pause -\item[smbfs] SMB networks client support - (for mounting Samba/Microsoft Windows shares on device) -\end{description} -\end{frame} - -\begin{frame} -\frametitle{distro features: hardware support} -\begin{description} -\item[alsa] ALSA/sound support - (OSS compatibility kernel modules installed if available) - \pause -\item[bluetooth] bluetooth support (integrated BT only) - \pause -\item[irda] IrDA support - \pause -\item[wifi] WiFi support (integrated only). - \pause -\item[keyboard] keyboard support (e.g. keymaps will be loaded during boot) -\end{description} -\end{frame} - -\begin{frame} -\frametitle{distro features: grahpics} -\begin{description} -\item[opengl] the Open Graphics Library, which is a cross-language, - multi-platform application programming interface used for rendering two - and three-dimensional graphics - \pause -\item[directfb] DirectFB support -\end{description} -\end{frame} - -\begin{frame} -\frametitle{distro features: networking} -\begin{description} -\item[ipsec] IPSec support - \pause -\item[ipv6] IPv6 support - \pause -\item[ppp] PPP dialup support -\end{description} -\end{frame} - -\begin{frame} -\frametitle{distro features: bus support} -\begin{description} -\item[pci] PCI bus support - \pause -\item[pcmcia] PCMCIA/CompactFlash support - \pause -\item[usbgadget] USB Gadget Device support (for USB networking/serial/storage) - \pause -\item[usbhost] USB Host support - (allows to connect external keyboard, mouse, storage, network etc) -\end{description} -\end{frame} - -\begin{frame} -\frametitle{distro features: software} -\begin{description} -\item[systemd] support for this init manager, which is a full replacement of - for init with parallel starting of services, reduced shell overhead, - and other features. This init manager is used by many distributions - \pause -\item[wayland] the Wayland display server protocol - and the library that supports it - \pause -\item[x11] X server and libraries -\end{description} -\end{frame} - -\begin{frame}[fragile] -\frametitle{use a DISTRO\_FEATURE} -Normally the distro features are used in package groups in a core layer. -e.g. 'meta/recipes-core/packagegroups/packagegroup-base.bb': -\begin{verbatim} -PACKAGES = ' \ - .. - ${@base_contains("DISTRO_FEATURES", \ - "opengl", "packagegroup-opengl", "", d)} \ - .. - ' -\end{verbatim} -\end{frame} - -\begin{frame}[fragile] -\frametitle{exkurs: package groups} -are recipes that are used to group packages together: -\begin{verbatim} -DESCRIPTION = “My Package Group” -LICENSE = “MIT” -LIC_FILES_CHECKSUM = “file://<licfile>;md5=<chksum> -inherit packagegroup -PROVIDES = “${PACKAGES}” -PACKAGES = “packagegroup-mypkg-apps packagegroup-mypkg-tools” -RDEPENDS_packagegroup-mypkg-apps = “sqlite3 python-core python-sqlite3” -RDEPENDS_pacakgegroup-mypkg-tools = “sudo gzip tar” -\end{verbatim} -it can be used, to simplify image definitions -\end{frame} - -\begin{frame}[fragile] -\frametitle{minimal distribution} -distros are defined in a layer, e.g. - -meta-linutronix/conf/distro/mini.conf: -\begin{verbatim} -meta-mini/conf/distro/mini.conf: -DISTRO = "mini" -DISTRO_NAME = "mini 1.0 (for foo devices)" -DISTRO_VERSION = "1.0" -DISTRO_CODENAME = "mal" -\end{verbatim} -\end{frame} -\begin{frame}[fragile] -\begin{verbatim} -SDK_VENDOR = "-linutronix" -SDK_VERSION := "${@'${DISTRO_VERSION}'}" -SDK_NAME = "${DISTRO}-${TCLIBC}-${SDK_ARCH}-${IMAGE_BASENAME}-${TUNE_PKGARCH}" -SDKPATH = "/opt/${DISTRO}/${SDK_VERSION}" -\end{verbatim} -\end{frame} -\begin{frame}[fragile] -\begin{verbatim} -MAINTAINER = "Manuel Traut <manut@linutronix.de>" -TARGET_VENDOR = "-linutronix" -LOCALCONF_VERSION = "1" -LAYER_CONF_VERSION ?= "6" -DISTRO_FEATURES ?= "opengl ${DISTRO_FEATURES_DEFAULT} ${DISTRO_FEATURES_LIBC}" -DISTRO_FEATURES_append = " systemd" -TCLIBCAPPEND = "" -\end{verbatim} -\end{frame} - -\begin{frame}[fragile] -\begin{verbatim} -CONNECTIVITY_CHECK_URIS ?= " \ - https://eula-downloads.yoctoproject.org/index.php \ - http://bugzilla.yoctoproject.org/report.cgi" -\end{verbatim} -\end{frame} - -\begin{frame}[fragile] -\begin{verbatim} -SANITY_TESTED_DISTROS ?= " \ - Ubuntu-14.04 \n \ - Debian-7.0 \n \ - Debian-7.1 \n \ - Debian-7.2 \n \ - Debian-7.3 \n \ - Debian-7.4 \n \ - " - -BB_SIGNATURE_HANDLER ?= 'OEBasicHash' -OELAYOUT_ABI = "8" -\end{verbatim} -\end{frame} - -\begin{frame}[fragile] -\frametitle{add distro to git repo} -\begin{verbatim} -poky/meta-mini % git add conf/distro/mini.conf -poky/meta-mini % git commit -sam 'add mini distro' -\end{verbatim} -\end{frame} - -\begin{frame}[fragile] -\frametitle{use mini distro} -edit DISTRO var in conf/local.conf -\begin{verbatim} -DISTRO ?= "mini" -\end{verbatim} -\end{frame} - -\subsection{Creating images} -\begin{frame}[fragile] -\frametitle{based on core-image class} -build image with ssh support -\begin{verbatim} -poky/build-ti % bitbake-layers show-recipes | grep ssh -Parsing recipes..done. -libssh: -openssh: -packagegroup-core-ssh-dropbear: -packagegroup-core-ssh-openssh: -\end{verbatim} -\pause -create the file -'meta-mini/recipes-bsp/mini-image/mini-image.bb' -\begin{verbatim} -IMAGE_INSTALL += "openssh" -inherit core-image -\end{verbatim} -\pause -to build the image, use: -\begin{verbatim} -poky/build-ti % bitbake mini-image -\end{verbatim} -\end{frame} - -\begin{frame}[fragile] -\frametitle{first errors and warnings} -\begin{verbatim} -recommended that you use a tested distribution. -ERROR: OE-core's config sanity checker detected a potential - misconfiguration. Either fix the cause of this error or - at your own risk disable the checker see sanity.conf). -Following is the list of potential problems / advisories: - -libsdl-native is set to be ASSUME_PROVIDED but sdl-config can't be -found in PATH. Please either install it, or configure qemu not to -require sdl. -ERROR: Execution of event handler 'check_sanity_eventhandler' failed -ERROR: Command execution failed: Exited with 1 -\end{verbatim} -\end{frame} -\begin{frame}[fragile] - - \frametitle{disable sdl support in qemu} -edit conf/local.conf: -\begin{verbatim} -# PACKAGECONFIG_pn-qemu-native = "sdl" -# PACKAGECONFIG_pn-nativesdk-qemu = "sdl" -# ASSUME_PROVIDED += "libsdl-native" +poky/build-ti % grep -r '@NAME' ../meta*/conf/machine \end{verbatim} +if no machine fits your needs, define your own! \end{frame} \subsection{Machines} @@ -955,13 +614,258 @@ IMAGE_FSTYPES += "sdcard" \end{verbatim} \end{frame} +\subsection{Define a distribution} +\begin{frame} +\frametitle{why define a distribution?} +\begin{itemize} +\item naming of the toolchain (codenames, vendor) + \pause +\item version numbers + \pause +\item enable default features +\end{itemize} +\end{frame} + +\begin{frame} +\frametitle{distro features: file-systems} +\begin{description} +\item[cramfs] CramFS support +\item[ext2] tools for supporting for devices with internal HDD/Microdrive + for storing files (instead of Flash only devices) +\item[nfs] NFS client support (for mounting NFS exports on device) +\item[smbfs] SMB networks client support + (for mounting Samba/Microsoft Windows shares on device) +\end{description} +\end{frame} + +\begin{frame} +\frametitle{distro features: hardware support} +\begin{description} +\item[alsa] ALSA/sound support + (OSS compatibility kernel modules installed if available) +\item[bluetooth] bluetooth support (integrated BT only) +\item[irda] IrDA support + \pause +\item[wifi] WiFi support (integrated only). +\item[keyboard] keyboard support (e.g. keymaps will be loaded during boot) +\end{description} +\end{frame} + +\begin{frame} +\frametitle{distro features: grahpics} +\begin{description} +\item[opengl] the Open Graphics Library, which is a cross-language, + multi-platform application programming interface used for rendering two + and three-dimensional graphics +\item[directfb] DirectFB support +\end{description} +\end{frame} + +\begin{frame} +\frametitle{distro features: networking} +\begin{description} +\item[ipsec] IPSec support +\item[ipv6] IPv6 support +\item[ppp] PPP dialup support +\end{description} +\end{frame} + +\begin{frame} +\frametitle{distro features: bus support} +\begin{description} +\item[pci] PCI bus support +\item[pcmcia] PCMCIA/CompactFlash support +\item[usbgadget] USB Gadget Device support (for USB networking/serial/storage) +\item[usbhost] USB Host support + (allows to connect external keyboard, mouse, storage, network etc) +\end{description} +\end{frame} + +\begin{frame} +\frametitle{distro features: software} +\begin{description} +\item[systemd] support for this init manager, which is a full replacement of + for init with parallel starting of services, reduced shell overhead, + and other features. This init manager is used by many distributions +\item[wayland] the Wayland display server protocol + and the library that supports it +\item[x11] X server and libraries +\end{description} +\end{frame} + +\begin{frame}[fragile] +\frametitle{use a DISTRO\_FEATURE} +Normally the distro features are used in package groups in a core layer. +e.g. 'meta/recipes-core/packagegroups/packagegroup-base.bb': +\begin{verbatim} +PACKAGES = ' \ + .. + ${@base_contains("DISTRO_FEATURES", \ + "opengl", "packagegroup-opengl", "", d)} \ + .. + ' +\end{verbatim} +\end{frame} + +\begin{frame}[fragile] +\frametitle{EXCURSUS: package groups} +are recipes that are used to group packages together: +\begin{verbatim} +DESCRIPTION = “My Package Group” +LICENSE = “MIT” +LIC_FILES_CHECKSUM = “file://<licfile>;md5=<chksum> +inherit packagegroup +PROVIDES = “${PACKAGES}” +PACKAGES = “packagegroup-mypkg-apps packagegroup-mypkg-tools” +RDEPENDS_packagegroup-mypkg-apps = “sqlite3 python-core python-sqlite3” +RDEPENDS_pacakgegroup-mypkg-tools = “sudo gzip tar” +\end{verbatim} +it can be used, to simplify image definitions +\end{frame} + +\begin{frame}[fragile] +\frametitle{minimal distribution} +distros are defined in a layer, e.g. + +meta-linutronix/conf/distro/mini.conf: +\begin{verbatim} +meta-mini/conf/distro/mini.conf: +DISTRO = "mini" +DISTRO_NAME = "mini 1.0 (for foo devices)" +DISTRO_VERSION = "1.0" +DISTRO_CODENAME = "mal" +\end{verbatim} +\end{frame} +\begin{frame}[fragile] +\begin{verbatim} +SDK_VENDOR = "-linutronix" +SDK_VERSION := "${@'${DISTRO_VERSION}'}" +SDK_NAME = "${DISTRO}-${TCLIBC}-${SDK_ARCH}-${IMAGE_BASENAME}-${TUNE_PKGARCH}" +SDKPATH = "/opt/${DISTRO}/${SDK_VERSION}" +\end{verbatim} +\end{frame} +\begin{frame}[fragile] +\begin{verbatim} +MAINTAINER = "Manuel Traut <manut@linutronix.de>" +TARGET_VENDOR = "-linutronix" +LOCALCONF_VERSION = "1" +LAYER_CONF_VERSION ?= "6" +DISTRO_FEATURES ?= "opengl ${DISTRO_FEATURES_DEFAULT} ${DISTRO_FEATURES_LIBC}" +DISTRO_FEATURES_append = " systemd" +TCLIBCAPPEND = "" +\end{verbatim} +\end{frame} + +\begin{frame}[fragile] +\begin{verbatim} +CONNECTIVITY_CHECK_URIS ?= " \ + https://eula-downloads.yoctoproject.org/index.php \ + http://bugzilla.yoctoproject.org/report.cgi" +\end{verbatim} +\end{frame} + +\begin{frame}[fragile] +\begin{verbatim} +SANITY_TESTED_DISTROS ?= " \ + Ubuntu-14.04 \n \ + Debian-7.0 \n \ + Debian-7.1 \n \ + Debian-7.2 \n \ + Debian-7.3 \n \ + Debian-7.4 \n \ + " + +BB_SIGNATURE_HANDLER ?= 'OEBasicHash' +OELAYOUT_ABI = "8" +\end{verbatim} +\end{frame} + +\begin{frame}[fragile] +\frametitle{add distro to git repo} +\begin{verbatim} +poky/meta-mini % git add conf/distro/mini.conf +poky/meta-mini % git commit -sam 'add mini distro' +\end{verbatim} +\end{frame} + +\subsection{Creating images} +\begin{frame}[fragile] +\frametitle{based on core-image class} +build image with ssh support +\begin{verbatim} +poky/build-ti % bitbake-layers show-recipes | grep ssh +Parsing recipes..done. +libssh: +openssh: +packagegroup-core-ssh-dropbear: +packagegroup-core-ssh-openssh: +\end{verbatim} +\pause +create the file +'meta-mini/recipes-bsp/mini-image/mini-image.bb' +\begin{verbatim} +IMAGE_INSTALL += "openssh" +inherit core-image +\end{verbatim} +\end{frame} + + +\begin{frame} +\frametitle{build configuration} +local.conf is used to configure +\begin{itemize} + \item the target machine + \item paths + \item the used distribution + \item package formats + \item arch of developer machine + \item additional image features + \item use additional classes + \item enable testing + \item devshell terminal + \item patch resolver + \item disk monitoring + \item sstate mirrors + \item qemu configuration + \item incompatible licenses, e.g. INCOMPATIBLE\_LICENSE = “GPLv3” +\end{itemize} +\end{frame} + +\begin{frame}[fragile] +\frametitle{override default config files} +default templates can be overridden by setting TEMPLATECONF +to e.g. meta-mini/conf during ./oe-init-buildenv. + +Then meta-mini/conf bblayers.conf.sample and local.conf.sample will +be used. + +The default location is specified in + +\begin{verbatim} +% cat .templateconf +# Template settings +TEMPLATECONF=${TEMPLATECONF:-meta-yocto/conf} +\end{verbatim} +\end{frame} + +\begin{frame}[fragile] + \frametitle{Excercise} + 1) Add sample configs to the meta-mini layer providing a valid + layer configuration and a build configuration that creates a + debug RFS for our self defined machine, by using our distribution. + The configus should Use packages in deb format and the shared + download directory from the poky directory. + + + 2) create a new build directory, e.g. build-bbb and build our self + defined image. +\end{frame} + \begin{frame} \frametitle{adding an own application} \begin{itemize} \item recipe already available? check http://layers.openembedded.org -\pause \item look for a similar recipe -\pause \item proper bbclass available? \end{itemize} on the next slides, we have a look what is useful for very simple applications, @@ -1134,15 +1038,23 @@ PNBLACKLIST[exoticware] = "Not supported by our organization." \end{verbatim} \end{frame} +\begin{frame} + \frametitle{Application Development Excercise} +\begin{itemize} +\item generate a standalone or integrated SDK +\item configure the SDK in eclipse +\item build and remote debug yesterdays application on the beaglebone-black +\item integrate the application into the image +\item build the image including your application +\end{itemize} +\end{frame} + \subsection{Resume} \begin{frame} \begin{itemize} \item Yocto is a huge collection of tools - \pause \item Bitbake can be used to create Images - \pause \item The quality of the Images depend on the maintainance of the Layers - \pause \item Only build your own distribution if you really need to! \end{itemize} \end{frame} |
