diff options
author | brian avery <avery.brian@gmail.com> | 2016-03-10 15:55:54 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-03-11 16:50:44 +0000 |
commit | 3f8d5bfdfdcf338a7e7d0925928cf936b7c325aa (patch) | |
tree | 4a19043a4d53a45a5b925558f8629ba06feaf9bc /meta/classes | |
parent | 39e1351cba6a9fa290c9e0677aebbe53134c483f (diff) | |
download | poky-3f8d5bfdfdcf338a7e7d0925928cf936b7c325aa.tar.gz |
toaster.bbclass: show packages that were setscened into existence too
We were previously ignoring pkgs that came in from a setscene like from
an sstate mirror). With this patch we can use pkgs than come from sstate
for image customisation as well.
Also remove unused variable.
[YOCTO #9137]
(From OE-Core rev: 4ea7f96ae28ff53867f5ffa4158076761676d288)
Signed-off-by: brian avery <brian.avery@intel.com>
Signed-off-by: Michael Wood <michael.g.wood@intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes')
-rw-r--r-- | meta/classes/toaster.bbclass | 25 |
1 files changed, 23 insertions, 2 deletions
diff --git a/meta/classes/toaster.bbclass b/meta/classes/toaster.bbclass index a17501e03e..1c0703c680 100644 --- a/meta/classes/toaster.bbclass +++ b/meta/classes/toaster.bbclass | |||
@@ -112,6 +112,26 @@ def _toaster_load_pkgdatafile(dirpath, filepath): | |||
112 | pass # ignore lines without valid key: value pairs | 112 | pass # ignore lines without valid key: value pairs |
113 | return pkgdata | 113 | return pkgdata |
114 | 114 | ||
115 | python toaster_package_dumpdata_setscene() { | ||
116 | """ | ||
117 | Dumps the data created by package_setscene | ||
118 | """ | ||
119 | # replicate variables from the package.bbclass | ||
120 | packages = d.getVar('PACKAGES', True) | ||
121 | pkgdatadir = d.getVar('PKGDATA_DIR', True) | ||
122 | # scan and send data for each package | ||
123 | lpkgdata = {} | ||
124 | for pkg in packages.split(): | ||
125 | try: | ||
126 | lpkgdata = _toaster_load_pkgdatafile(pkgdatadir + "/runtime/", pkg) | ||
127 | except: | ||
128 | # these are typically foo-locale which actually point into foo-locale-<language> in runtime-rprovides | ||
129 | bb.note("toaster_package_dumpdata_setscene: failed to load pkg information for: %s:%s"%(pkg,sys.exc_info()[0])) | ||
130 | # Fire an event containing the pkg data | ||
131 | bb.event.fire(bb.event.MetadataEvent("SinglePackageInfo", lpkgdata), d) | ||
132 | |||
133 | } | ||
134 | |||
115 | 135 | ||
116 | python toaster_package_dumpdata() { | 136 | python toaster_package_dumpdata() { |
117 | """ | 137 | """ |
@@ -120,8 +140,6 @@ python toaster_package_dumpdata() { | |||
120 | # replicate variables from the package.bbclass | 140 | # replicate variables from the package.bbclass |
121 | 141 | ||
122 | packages = d.getVar('PACKAGES', True) | 142 | packages = d.getVar('PACKAGES', True) |
123 | pkgdest = d.getVar('PKGDEST', True) | ||
124 | |||
125 | pkgdatadir = d.getVar('PKGDESTWORK', True) | 143 | pkgdatadir = d.getVar('PKGDESTWORK', True) |
126 | 144 | ||
127 | # scan and send data for each package | 145 | # scan and send data for each package |
@@ -382,6 +400,9 @@ toaster_collect_task_stats[eventmask] = "bb.event.BuildCompleted bb.build.TaskSu | |||
382 | addhandler toaster_buildhistory_dump | 400 | addhandler toaster_buildhistory_dump |
383 | toaster_buildhistory_dump[eventmask] = "bb.event.BuildCompleted" | 401 | toaster_buildhistory_dump[eventmask] = "bb.event.BuildCompleted" |
384 | 402 | ||
403 | do_packagedata_setscene[postfuncs] += "toaster_package_dumpdata_setscene " | ||
404 | do_packagedata_setscene[vardepsexclude] += "toaster_package_dumpdata_setscene " | ||
405 | |||
385 | do_package[postfuncs] += "toaster_package_dumpdata " | 406 | do_package[postfuncs] += "toaster_package_dumpdata " |
386 | do_package[vardepsexclude] += "toaster_package_dumpdata " | 407 | do_package[vardepsexclude] += "toaster_package_dumpdata " |
387 | 408 | ||