summaryrefslogtreecommitdiff
path: root/meta/conf/bitbake.conf
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2015-05-26 11:42:26 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2015-05-26 13:06:05 +0100
commit03482382b797f3501c3fb0df0fe12bd4e5e51a39 (patch)
treeefccc09900e2b3b88be981f0acfcb61254c1d01b /meta/conf/bitbake.conf
parent676309f25ae57794bc270994fede31e8c7b9c83c (diff)
downloadopenembedded-core-03482382b797f3501c3fb0df0fe12bd4e5e51a39.tar.gz
openembedded-core-03482382b797f3501c3fb0df0fe12bd4e5e51a39.tar.bz2
openembedded-core-03482382b797f3501c3fb0df0fe12bd4e5e51a39.zip
bitbake.conf: Use immediate expansion for os.uname()
Use immediate expansion for BUILD_ARCH and BUILD_OS since there is no point in repeatedly calling os.uname() throughout parsing. This is worth around 2% of parsing time, small but measurable. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/conf/bitbake.conf')
-rw-r--r--meta/conf/bitbake.conf6
1 files changed, 4 insertions, 2 deletions
diff --git a/meta/conf/bitbake.conf b/meta/conf/bitbake.conf
index 9c72044d8d..2b86442b1d 100644
--- a/meta/conf/bitbake.conf
+++ b/meta/conf/bitbake.conf
@@ -81,8 +81,10 @@ ROOT_HOME ??= "/home/root"
# Architecture-dependent build variables.
##################################################################
-BUILD_ARCH = "${@os.uname()[4]}"
-BUILD_OS = "${@os.uname()[0].lower()}"
+# Immediate expansion since there is no point in reapeatedly calling
+# os.uname() throughout parsing
+BUILD_ARCH := "${@os.uname()[4]}"
+BUILD_OS := "${@os.uname()[0].lower()}"
BUILD_VENDOR = ""
BUILD_SYS = "${BUILD_ARCH}${BUILD_VENDOR}-${BUILD_OS}"
BUILD_PREFIX = ""