xen-image-minimal: if DISTRO_FEATURES is missing xen error
PATCH 1/1 xen-image-minimal: if DISTRO_FEATURES is missing xen error
It can be confusing to users why things are failing with missing kernel dependencies when you don't have 'xen' in your DISTRO_FEATURES. This should provide them with some better info.
---
The result of this change is the following output:
| DEBUG: Executing shell function do_check_xen_state | ERROR: DISTRO_FEATURES does not contain 'xen' | WARNING: exit code 1 from a shell command.
--- recipes-extended/images/xen-image-minimal.bb | 8 ++++++++ 1 file changed, 8 insertions(+)
recipes-extended/images/xen-image-minimal.bb +8 -0
@@ -20,6 +20,14 @@ LICENSE = "MIT" inherit core-image +do_check_xen_state() { + if [ "${@bb.utils.contains('DISTRO_FEATURES', 'xen', ' yes', 'no', d)}" = "no" ]; then + die "DISTRO_FEATURES does not contain 'xen'" + fi +} + +addtask check_xen_state before do_rootfs + syslinux_iso_populate_append() { install -m 0444 ${STAGING_DATADIR}/syslinux/libcom32.c32 ${ISODIR}${ISOLINUXDIR} install -m 0444 ${STAGING_DATADIR}/syslinux/mboot.c32 ${ISODIR}${ISOLINUXDIR}
Signature · 1 line
2.4.10
Quoted 27 lines · Doug Goldstein
It can be confusing to users why things are failing with missing kernel dependencies when you don't have 'xen' in your
DISTRO_FEATURES. This should provide them with some better info.Signed-off-by Doug Goldstein <[email protected]>---
The result of this change is the following output:
| DEBUG: Executing shell function do_check_xen_state | ERROR: DISTRO_FEATURES does not contain 'xen' | WARNING: exit code 1 from a shell command.--- recipes-extended/images/xen-image-minimal.bb | 8 ++++++++ 1 file changed, 8 insertions(+)recipes-extended/images/xen-image-minimal.bb +1
-0@@ -20,6 +20,14 @@ LICENSE = "MIT" inherit core-image +do_check_xen_state() {
recipes-extended/images/xen-image-minimal.bb LICENSE = "MIT" · line 33
Quoted 10 lines
recipes-extended/images/xen-image-minimal.bb +7
-0+ if [ "${@bb.utils.contains('DISTRO_FEATURES', 'xen', ' yes', 'no', d)}" = "no" ]; then + die "DISTRO_FEATURES does not contain 'xen'" + fi +} + +addtask check_xen_state before do_rootfs + syslinux_iso_populate_append() { install -m 0444 ${STAGING_DATADIR}/syslinux/libcom32.c32 ${ISODIR}${ISOLINUXDIR} install -m 0444 ${STAGING_DATADIR}/syslinux/mboot.c32 ${ISODIR}${ISOLINUXDIR}
Ping? This would have solved Andrew Stuart's thread from 11/11/16.
Signature · 1 line
Doug Goldstein
Quoted 39 lines · Doug Goldstein
Quoted 13 lines · Doug Goldstein
It can be confusing to users why things are failing with missing kernel dependencies when you don't have 'xen' in your
DISTRO_FEATURES. This should provide them with some better info.Signed-off-by Doug Goldstein <[email protected]>---
The result of this change is the following output:
| DEBUG: Executing shell function do_check_xen_state | ERROR: DISTRO_FEATURES does not contain 'xen' | WARNING: exit code 1 from a shell command.Review
Quoted 5 lines
--- recipes-extended/images/xen-image-minimal.bb | 8 ++++++++ 1 file changed, 8 insertions(+)(quoted diff) +0
-0b/recipes-extended/images/xen-image-minimal.bb
recipes-extended/images/xen-image-minimal.bb LICENSE = "MIT" · line 24
Quoted 9 lines
index 26b6d06..b8c2002 100644
recipes-extended/images/xen-image-minimal.bb +2
-0@@ -20,6 +20,14 @@ LICENSE = "MIT" inherit core-image +do_check_xen_state() { + if [ "${@bb.utils.contains('DISTRO_FEATURES', 'xen', ' yes', 'no',d)}" = "no" ]; then
recipes-extended/images/xen-image-minimal.bb LICENSE = "MIT"
Quoted 8 lines
recipes-extended/images/xen-image-minimal.bb +6
-0+ die "DISTRO_FEATURES does not contain 'xen'" + fi +} + +addtask check_xen_state before do_rootfs + syslinux_iso_populate_append() { install -m 0444 ${STAGING_DATADIR}/syslinux/libcom32.c32${ISODIR}${ISOLINUXDIR}
Quoted 6 lines
recipes-extended/images/xen-image-minimal.bb LICENSE = "MIT" · line 33
Quoted 1 line
recipes-extended/images/xen-image-minimal.bb +0
-0install -m 0444 ${STAGING_DATADIR}/syslinux/mboot.c32${ISODIR}${ISOLINUXDIR}
Quoted 1 line
Ping? This would have solved Andrew Stuart's thread from 11/11/16.
Yep, looks fine .. again, I'm not sure how this was missed. I'll merge it shortly.
Bruce
Quoted 5 lines
--
Doug Goldstein
Signature · 2 lines
"Thou shalt not follow the NULL pointer, for chaos and madness await thee at its end"