]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commitdiff
autotools.bbclass: Add glibc-site to deps rbt/glibc-site
authorRobert Yang <liezhi.yang@windriver.com>
Wed, 9 Jan 2019 04:26:31 +0000 (12:26 +0800)
committerRobert Yang <liezhi.yang@windriver.com>
Thu, 10 Jan 2019 03:31:20 +0000 (19:31 -0800)
This can reduce configure time, here is a test result:

$ bitbake recipe -cconfigure && bitbake recipe -ccleansstate && time bitbake recipe -cconfigure
- gettext:
    before: 2m38.382s
    after: 2m33.099s

- coreutils:
    before: 1m19.967s
    after: 1m13.574s

- bison:
    before: 0m56.203s
    after: 0m50.134s

But there is nearly no difference when bitbake core-image-minimal or
core-image-sato, I think it is because glibc-site requires about 30s to build,
and these recipes depend on it, so there is no difference when do large builds.

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
meta/classes/autotools.bbclass

index 8768a6ad687ecb49f9331698dc768f890c50923a..9abafaf0d722ada182f3f68e29aaa5b0023c4267 100644 (file)
@@ -17,6 +17,11 @@ def autotools_dep_prepend(d):
                         and not d.getVar('INHIBIT_DEFAULT_DEPS'):
             deps += 'libtool-cross '
 
+    if not (d.getVar('INHIBIT_DEFAULT_DEPS') or \
+            bb.data.inherits_class('native', d) or \
+            bb.data.inherits_class('cross', d)):
+        deps += 'glibc-site '
+
     return deps + 'gnu-config-native '
 
 DEPENDS_prepend = "${@autotools_dep_prepend(d)} "