Patchwork [4/8] conf/layer.conf: Use .= to append to BBPATH and =+ for BBFILES

login
register
mail settings
Submitter Khem Raj
Date May 7, 2011, 7:53 a.m.
Message ID <2bd1ade80a799c7b90fc6db9b3e1138234c5651a.1304754527.git.raj.khem@gmail.com>
Download mbox | patch
Permalink /patch/3321/
State New, archived
Headers show

Comments

Khem Raj - May 7, 2011, 7:53 a.m.
Appending to BBPATH gives a definite order to BBLAYERS which
means paths are preferred in order from left to right.

Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
 meta/conf/layer.conf |   13 ++++++++++---
 1 files changed, 10 insertions(+), 3 deletions(-)

Patch

diff --git a/meta/conf/layer.conf b/meta/conf/layer.conf
index 5287417..10a6948 100644
--- a/meta/conf/layer.conf
+++ b/meta/conf/layer.conf
@@ -1,9 +1,16 @@ 
 BBPATH ?= ""
 # We have a conf and classes directory, add to BBPATH
-BBPATH := "${BBPATH}:${LAYERDIR}"
-
+BBPATH .= ":${LAYERDIR}"
 # We have a packages directory, add to BBFILES
-BBFILES := "${BBFILES} ${LAYERDIR}/packages/*/*.bb ${LAYERDIR}/recipes-*/*/*.bb"
+# packages is still there because metadata_scm.bbclass still uses
+# it to deduce the repo directory and thats the reason to prepend
+# to BBFILES here because this class uses the first entry in
+# BBFILES to calculate the scm base.
+# since the order of BBFLILES is not that important its acted upon
+# using BBFILES_PRIORITY we are ok to keep the oe-core BBFILES dir
+# at top
+
+BBFILES =+ "${LAYERDIR}/packages/*/*.bb ${LAYERDIR}/recipes-*/*/*.bb"
 
 BBFILE_COLLECTIONS += "normal"
 BBFILE_PATTERN_normal := "^${LAYERDIR}/"