@@ -114,10 +114,9 @@ python () {
if ar_recipe == "1":
d.appendVarFlag('do_deploy_archives', 'depends', ' %s:do_ar_recipe' % pn)
- # Output the srpm package
- ar_srpm = d.getVarFlag('ARCHIVER_MODE', 'srpm')
- if ar_srpm == "1":
- if d.getVar('PACKAGES') != '' and d.getVar('IMAGE_PKGTYPE') == 'rpm':
+ # Output the SRPM package
+ if d.getVarFlag('ARCHIVER_MODE', 'srpm') == "1" and d.getVar('PACKAGES'):
+ if "package_rpm" in d.getVar('PACKAGE_CLASSES'):
d.appendVarFlag('do_deploy_archives', 'depends', ' %s:do_package_write_rpm' % pn)
if ar_dumpdata == "1":
d.appendVarFlag('do_package_write_rpm', 'depends', ' %s:do_dumpdata' % pn)
@@ -129,6 +128,8 @@ python () {
d.appendVarFlag('do_package_write_rpm', 'depends', ' %s:do_ar_patched' % pn)
elif ar_src == "configured":
d.appendVarFlag('do_package_write_rpm', 'depends', ' %s:do_ar_configured' % pn)
+ else:
+ bb.fatal("ARCHIVER_MODE[srpm] needs package_rpm in PACKAGE_CLASSES")
}
# Take all the sources for a recipe and puts them in WORKDIR/archiver-work/.
The requirement for images being built using RPM is too strict to have access to the RPM functions, simply checking that package_rpm is in PACKAGE_CLASSES is sufficient. Also fail if SRPMs are requested but package_rpm isn't enabled, instead of silently not doing what we were asked. Signed-off-by: Ross Burton <ross.burton@intel.com> --- meta/classes/archiver.bbclass | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) -- 2.11.0 -- _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core