mirror of
https://git.yoctoproject.org/poky
synced 2026-04-18 21:32:12 +02:00
archiver: don't require that images are built using RPM to build SRPMs
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. (From OE-Core rev: cdae5c41e4f67a8757efc5ce1ef11d730edc3af1) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
add548491a
commit
ffa0eb5fdc
@@ -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/.
|
||||
|
||||
Reference in New Issue
Block a user