bitbake.conf: sanitize FILESPATH
authorChris Larson <chris_larson@mentor.com>
Sun, 17 Oct 2010 05:34:51 +0000 (22:34 -0700)
committerChris Larson <chris_larson@mentor.com>
Sun, 17 Oct 2010 05:54:11 +0000 (22:54 -0700)
- reverse OVERRIDES
- drop empty overrides
- uniq the list
- use nested variable references rather than getVar

Signed-off-by: Chris Larson <chris_larson@mentor.com>
conf/bitbake.conf

index c2359dc..c9736e0 100644 (file)
@@ -271,7 +271,7 @@ FILES_${PN}-locale = "${datadir}/locale"
 FILE_DIRNAME = "${@os.path.dirname(bb.data.getVar('FILE', d))}"
 FILESPATHBASE = "${FILE_DIRNAME}"
 FILESPATHPKG = "${PF}:${P}:${PN}:${BP}:${BPN}:files:."
-FILESPATH = "${@':'.join([os.path.normpath(os.path.join(fp, p, o)) for fp in d.getVar('FILESPATHBASE', 1).split(':') for p in d.getVar('FILESPATHPKG', 1).split(':') for o in (d.getVar('OVERRIDES', 1) + ':').split(':')])}"
+FILESPATH = "${@':'.join(uniq(os.path.normpath(os.path.join(fp, p, o)) for fp in '${FILESPATHBASE}'.split(':') for p in '${FILESPATHPKG}'.split(':') for o in reversed([''] + filter(None, '${OVERRIDES}'.split(':')))))}"
 FILESDIR = "${@bb.which(d.getVar('FILESPATH', 1), '.')}"
 
 ##################################################################