diff options
author | Chris Larson <chris_larson@mentor.com> | 2010-11-23 20:08:06 -0700 |
---|---|---|
committer | Richard Purdie <rpurdie@linux.intel.com> | 2011-01-04 14:46:44 +0000 |
commit | 8a938d567f4439e114e50d93edc3c72a55f7b4d8 (patch) | |
tree | 0736ae48f25da9509e5b90d560013242f4e5f482 /bitbake/lib/bb/cache.py | |
parent | a92caf45c86809274def5a80bc58afcf8b7ad044 (diff) | |
download | poky-8a938d567f4439e114e50d93edc3c72a55f7b4d8.tar.gz |
cache: ensure 'pn' is included in the pkgvars
(Bitbake rev: cefc28a2aa1e5703119dacfd885c8c159a1e47a3)
Signed-off-by: Chris Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
Diffstat (limited to 'bitbake/lib/bb/cache.py')
-rw-r--r-- | bitbake/lib/bb/cache.py | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/bitbake/lib/bb/cache.py b/bitbake/lib/bb/cache.py index 2b92ed01f0..b5be37ea8c 100644 --- a/bitbake/lib/bb/cache.py +++ b/bitbake/lib/bb/cache.py | |||
@@ -106,9 +106,13 @@ class RecipeInfo(namedtuple('RecipeInfo', recipe_fields)): | |||
106 | 106 | ||
107 | @classmethod | 107 | @classmethod |
108 | def from_metadata(cls, filename, metadata): | 108 | def from_metadata(cls, filename, metadata): |
109 | pn = cls.getvar('PN', metadata) | ||
110 | packages = cls.listvar('PACKAGES', metadata) | ||
111 | if not pn in packages: | ||
112 | packages.append(pn) | ||
113 | |||
109 | tasks = metadata.getVar('__BBTASKS', False) | 114 | tasks = metadata.getVar('__BBTASKS', False) |
110 | 115 | ||
111 | packages = cls.listvar('PACKAGES', metadata) | ||
112 | return RecipeInfo( | 116 | return RecipeInfo( |
113 | tasks = tasks, | 117 | tasks = tasks, |
114 | basetaskhashes = cls.taskvar('BB_BASEHASH', tasks, metadata), | 118 | basetaskhashes = cls.taskvar('BB_BASEHASH', tasks, metadata), |
@@ -121,8 +125,8 @@ class RecipeInfo(namedtuple('RecipeInfo', recipe_fields)): | |||
121 | 125 | ||
122 | skipped = cls.getvar('__SKIPPED', metadata), | 126 | skipped = cls.getvar('__SKIPPED', metadata), |
123 | timestamp = bb.parse.cached_mtime(filename), | 127 | timestamp = bb.parse.cached_mtime(filename), |
124 | packages = packages, | 128 | packages = cls.listvar('PACKAGES', metadata), |
125 | pn = cls.getvar('PN', metadata), | 129 | pn = pn, |
126 | pe = cls.getvar('PE', metadata), | 130 | pe = cls.getvar('PE', metadata), |
127 | pv = cls.getvar('PV', metadata), | 131 | pv = cls.getvar('PV', metadata), |
128 | pr = cls.getvar('PR', metadata), | 132 | pr = cls.getvar('PR', metadata), |
@@ -563,20 +567,16 @@ class CacheData(object): | |||
563 | self.packages[package].append(fn) | 567 | self.packages[package].append(fn) |
564 | rprovides += info.rprovides_pkg[package] | 568 | rprovides += info.rprovides_pkg[package] |
565 | 569 | ||
566 | for package in info.packages_dynamic: | ||
567 | self.packages_dynamic[package].append(fn) | ||
568 | |||
569 | for rprovide in rprovides: | 570 | for rprovide in rprovides: |
570 | self.rproviders[rprovide].append(fn) | 571 | self.rproviders[rprovide].append(fn) |
571 | 572 | ||
573 | for package in info.packages_dynamic: | ||
574 | self.packages_dynamic[package].append(fn) | ||
575 | |||
572 | # Build hash of runtime depends and rececommends | 576 | # Build hash of runtime depends and rececommends |
573 | for package in info.packages + [info.pn]: | 577 | for package in info.packages + [info.pn]: |
574 | rundeps, runrecs = list(info.rdepends), list(info.rrecommends) | 578 | self.rundeps[fn][package] = list(info.rdepends) + info.rdepends_pkg[package] |
575 | if package in info.packages: | 579 | self.runrecs[fn][package] = list(info.rrecommends) + info.rrecommends_pkg[package] |
576 | rundeps += info.rdepends_pkg[package] | ||
577 | runrecs += info.rrecommends_pkg[package] | ||
578 | self.rundeps[fn][package] = rundeps | ||
579 | self.runrecs[fn][package] = runrecs | ||
580 | 580 | ||
581 | # Collect files we may need for possible world-dep | 581 | # Collect files we may need for possible world-dep |
582 | # calculations | 582 | # calculations |