From 6fd92740461aedd9f48265d16cb41e74a81f4cde Mon Sep 17 00:00:00 2001 From: Scott Rifenbark Date: Wed, 17 Apr 2013 12:51:56 -0700 Subject: dev-manual: Edits to "Using .bbappend Files" I re-wrote this to more clearly describe use. (From yocto-docs rev: c3d6eecd38c6d4c8b4e0b4e134cbd53ae3fd2aee) Signed-off-by: Scott Rifenbark Signed-off-by: Richard Purdie --- .../dev-manual/dev-manual-common-tasks.xml | 52 +++++++++++++++------- 1 file changed, 35 insertions(+), 17 deletions(-) (limited to 'documentation') diff --git a/documentation/dev-manual/dev-manual-common-tasks.xml b/documentation/dev-manual/dev-manual-common-tasks.xml index b263420813..b18d80b41f 100644 --- a/documentation/dev-manual/dev-manual-common-tasks.xml +++ b/documentation/dev-manual/dev-manual-common-tasks.xml @@ -395,7 +395,7 @@ LICENSE = "MIT" LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58 \ file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420" - PR = "r20" + PR = "r21" SRC_URI = "file://config file://machconfig" S = "${WORKDIR}" @@ -410,9 +410,15 @@ if [ -s "${S}/machconfig" ]; then install -m 0644 ${S}/machconfig ${D}${sysconfdir}/formfactor/ fi - } - - Here is the append file, which is named + } + In the main recipe, note the + SRC_URI + variable, which tells the OpenEmbedded build system where to + find files during the build. + + + + Following is the append file, which is named formfactor_0.0.bbappend and is from the Crown Bay BSP Layer named meta-intel/meta-crownbay. @@ -422,21 +428,33 @@ PRINC := "${@int(PRINC) + 2}" - This example adds or overrides files in - SRC_URI - within a .bbappend by extending the path - BitBake uses to search for files. - The most reliable way to do this is by prepending the + + + + By default, the build system uses the + FILESPATH + variable to locate files. + This append file extends the locations by setting the FILESEXTRAPATHS variable. - For example, if you have your files in a directory that is named - the same as your package - (PN), - you can add this directory by adding the following to your - .bbappend file: - - FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:" - + Setting this variable in the .bbappend + file is the most reliable and recommended method for adding + directories to the search path used by the build system + to find files. + + + + The statement in this example extends the directories to include + ${THISDIR}/${PN}, + which resolves to the same directory in which the append file + resides (i.e. + meta-intel/meta-crownbay/recipes-bsp/formfactor. + This implies that you must have the supporting directory + structure set up that will contain any files or patches you + will be including from the layer. + + + Using the immediate expansion assignment operator := is important because of the reference to THISDIR. -- cgit v1.2.3-54-g00ecf