summaryrefslogtreecommitdiff
path: root/meta/classes/toaster.bbclass
diff options
context:
space:
mode:
authorbrian avery <avery.brian@gmail.com>2016-03-10 15:55:54 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-03-11 16:50:26 +0000
commit4ea7f96ae28ff53867f5ffa4158076761676d288 (patch)
tree13df6a94069f6f59d37bc03fde1f49f84cf28436 /meta/classes/toaster.bbclass
parente24c8be86080bd67ef1c5aa3b9885396dc2774b2 (diff)
downloadopenembedded-core-4ea7f96ae28ff53867f5ffa4158076761676d288.tar.gz
openembedded-core-4ea7f96ae28ff53867f5ffa4158076761676d288.tar.bz2
openembedded-core-4ea7f96ae28ff53867f5ffa4158076761676d288.zip
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] 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/toaster.bbclass')
-rw-r--r--meta/classes/toaster.bbclass25
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):
pass # ignore lines without valid key: value pairs
return pkgdata
+python toaster_package_dumpdata_setscene() {
+ """
+ Dumps the data created by package_setscene
+ """
+ # replicate variables from the package.bbclass
+ packages = d.getVar('PACKAGES', True)
+ pkgdatadir = d.getVar('PKGDATA_DIR', True)
+ # scan and send data for each package
+ lpkgdata = {}
+ for pkg in packages.split():
+ try:
+ lpkgdata = _toaster_load_pkgdatafile(pkgdatadir + "/runtime/", pkg)
+ except:
+ # these are typically foo-locale which actually point into foo-locale-<language> in runtime-rprovides
+ bb.note("toaster_package_dumpdata_setscene: failed to load pkg information for: %s:%s"%(pkg,sys.exc_info()[0]))
+ # Fire an event containing the pkg data
+ bb.event.fire(bb.event.MetadataEvent("SinglePackageInfo", lpkgdata), d)
+
+}
+
python toaster_package_dumpdata() {
"""
@@ -120,8 +140,6 @@ python toaster_package_dumpdata() {
# replicate variables from the package.bbclass
packages = d.getVar('PACKAGES', True)
- pkgdest = d.getVar('PKGDEST', True)
-
pkgdatadir = d.getVar('PKGDESTWORK', True)
# scan and send data for each package
@@ -382,6 +400,9 @@ toaster_collect_task_stats[eventmask] = "bb.event.BuildCompleted bb.build.TaskSu
addhandler toaster_buildhistory_dump
toaster_buildhistory_dump[eventmask] = "bb.event.BuildCompleted"
+do_packagedata_setscene[postfuncs] += "toaster_package_dumpdata_setscene "
+do_packagedata_setscene[vardepsexclude] += "toaster_package_dumpdata_setscene "
+
do_package[postfuncs] += "toaster_package_dumpdata "
do_package[vardepsexclude] += "toaster_package_dumpdata "