diff options
author | Chris Larson <chris_larson@mentor.com> | 2010-05-23 10:41:09 -0700 |
---|---|---|
committer | Chris Larson <chris_larson@mentor.com> | 2010-06-10 11:35:01 -0700 |
commit | 4d060ecf3da4ee27547e7456df1198a450461ab0 (patch) | |
tree | 8cff3499a48c514e6dc635142150bfb5dd01d6a7 /conf/bitbake.conf | |
parent | 52ef9265223084d9d4ab38a6ff12c5be78ee380d (diff) |
bitbake.conf: Drop some unnecessary getVar usage in python snippets
Signed-off-by: Chris Larson <chris_larson@mentor.com>
Diffstat (limited to 'conf/bitbake.conf')
-rw-r--r-- | conf/bitbake.conf | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/conf/bitbake.conf b/conf/bitbake.conf index 1980f43416..397dbc2701 100644 --- a/conf/bitbake.conf +++ b/conf/bitbake.conf @@ -128,7 +128,8 @@ EXEEXT = "${HOST_EXEEXT}" BASE_PACKAGE_ARCH = "${HOST_ARCH}" PACKAGE_ARCH = "${BASE_PACKAGE_ARCH}" PACKAGE_EXTRA_ARCHS ?= "" -MACHINE_ARCH = "${@[bb.data.getVar('BASE_PACKAGE_ARCH', d, 1), bb.data.getVar('MACHINE', d, 1)][bool(bb.data.getVar('MACHINE', d, 1))]}" +MACHINE_ARCH = "${@oe.utils.ifelse(bool(d.getVar('MACHINE', True)), '${MACHINE}', \ + 'BASE_PACKAGE_ARCH')}" PACKAGE_ARCHS = "all any noarch ${TARGET_ARCH} ${PACKAGE_EXTRA_ARCHS} ${MACHINE}" MULTIMACH_ARCH = "${PACKAGE_ARCH}" @@ -174,9 +175,9 @@ ASSUME_PROVIDED = "\ ################################################################## # Package default variables. ################################################################## -PN = "${@bb.parse.BBHandler.vars_from_file(bb.data.getVar('FILE',d),d)[0] or 'defaultpkgname'}" -PV = "${@bb.parse.BBHandler.vars_from_file(bb.data.getVar('FILE',d),d)[1] or '1.0'}" -PR = "${@bb.parse.BBHandler.vars_from_file(bb.data.getVar('FILE',d),d)[2] or 'r0'}" +PN = "${@bb.parse.BBHandler.vars_from_file('${FILE}', d)[0] or 'defaultpkgname'}" +PV = "${@bb.parse.BBHandler.vars_from_file('${FILE}', d)[1] or '1.0'}" +PR = "${@bb.parse.BBHandler.vars_from_file('${FILE}', d)[2] or 'r0'}" PF = "${PN}-${EXTENDPE}${PV}-${PR}" PE ?= "0" EXTENDPE = "${@int('${PE}') and '${PE}_' or ''}" @@ -192,7 +193,7 @@ MACHINE_KERNEL_PR = "" # Automatically derives "foo" from "foo-native", "foo-cross" or "foo-initial" # otherwise it is the same as PN and P SPECIAL_PKGSUFFIX = "-native -cross -initial -intermediate -nativesdk -crosssdk -cross-canadian -sdk" -BPN = "${@base_prune_suffix(bb.data.getVar('PN', d, True), bb.data.getVar('SPECIAL_PKGSUFFIX', d, True).split(), d)}" +BPN = "${@base_prune_suffix('${PN}', '${SPECIAL_PKGSUFFIX}'.split(), d)}" BP = "${BPN}-${PV}" # Package info. |