bin/bitbake: Micro Optimisation
authorHolger Hans Peter Freyther <zecke@selfish.org>
Tue, 21 Mar 2006 21:53:28 +0000 (21:53 +0000)
committerHolger Hans Peter Freyther <zecke@selfish.org>
Tue, 21 Mar 2006 21:53:28 +0000 (21:53 +0000)
    Do not build the World Package List unless we want
    to build 'world'. This saves from 10 to 20 seconds
    on a usual build.
    I think people doing a world build can survice the
    extra seconds.

bin/bitbake

index 457fbb7..59caf07 100755 (executable)
@@ -701,7 +701,12 @@ class BBCooker:
         for p in self.pkgdata.keys():
             self.status.bbfile_priority[p] = calc_bbfile_priority(p)
 
-        # Build package list for "bitbake world"
+    def buildWorldTargetList(self):
+        """
+         Build package list for "bitbake world"
+        """
+        all_depends = self.status.all_depends
+        pn_provides = self.status.pn_provides
         bb.debug(1, "collating packages for \"world\"")
         for f in self.status.possible_world:
             terminal = True
@@ -883,6 +888,7 @@ class BBCooker:
                 self.showVersions()
                 sys.exit( 0 )
             if 'world' in pkgs_to_build:
+                self.buildWorldTargetList()
                 pkgs_to_build.remove('world')
                 for t in self.status.world_target:
                     pkgs_to_build.append(t)