summaryrefslogtreecommitdiff
path: root/meta/conf
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2014-01-27 14:39:48 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2014-01-27 22:08:58 +0000
commit99777f60342ce1371e3960661035ca7cd89f96f5 (patch)
tree3b71712e6484951ae02f432ff198a7c66bc65fd5 /meta/conf
parent0ae27a55759e7c4254e704e18b304d40013cb5c3 (diff)
downloadopenembedded-core-99777f60342ce1371e3960661035ca7cd89f96f5.tar.gz
openembedded-core-99777f60342ce1371e3960661035ca7cd89f96f5.tar.bz2
openembedded-core-99777f60342ce1371e3960661035ca7cd89f96f5.zip
local.conf.sample: Add automatic defaults for BB_NUMBER_THREADS and PARALLEL_MAKE
Its rather sad that people don't appear to read local.conf and then complain about slow builds when they're just using a single thread. Most systems have more than one core now so we might as well use a more automatic default for these values. This may lead to better experiences for new users. [YOCTO #2528] Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/conf')
-rw-r--r--meta/conf/local.conf.sample6
1 files changed, 6 insertions, 0 deletions
diff --git a/meta/conf/local.conf.sample b/meta/conf/local.conf.sample
index c977129139..1d893af23a 100644
--- a/meta/conf/local.conf.sample
+++ b/meta/conf/local.conf.sample
@@ -18,12 +18,18 @@
# option determines how many tasks bitbake should run in parallel:
#
#BB_NUMBER_THREADS ?= "4"
+#
+# Default to setting automatically based on cpu count
+BB_NUMBER_THREADS ?= "${@oe.utils.cpu_count()}"
#
# The second option controls how many processes make should run in parallel when
# running compile tasks:
#
#PARALLEL_MAKE ?= "-j 4"
#
+# Default to setting automatically based on cpu count
+PARALLEL_MAKE ?= "-j ${@oe.utils.cpu_count()}"
+#
# For a quad-core machine, BB_NUMBER_THREADS = "4", PARALLEL_MAKE = "-j 4" would
# be appropriate for example.