meta/classes/testimage.bbclass: Only validate IMAGE_FSTYPES when is QEMU
PATCH 1/1 meta/classes/testimage.bbclass: Only validate IMAGE_FSTYPES when is QEMU
When use simpleremote target the flash/boot process is executed manually, the IMAGE_FSTYPES validation is only needed when execute testimage against qemu.
The supported_fstypes comes from oeqa.core.target.qemu module.
--- meta/classes/testimage.bbclass | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-)
meta/classes/testimage.bbclass +7 -6
@@ -194,12 +194,13 @@ def testimage_main(d): machine = d.getVar("MACHINE") # Get rootfs - fstypes = [fs for fs in d.getVar('IMAGE_FSTYPES').split(' ') - if fs in supported_fstypes] - if not fstypes: - bb.fatal('Unsupported image type built. Add a comptible image to ' - 'IMAGE_FSTYPES. Supported types: %s' % - ', '.join(supported_fstypes)) + fstypes = d.getVar('IMAGE_FSTYPES') + if d.getVar("TEST_TARGET") == "qemu": + fstypes = [fs for fs in fstypes if fs in supported_fstypes] + if not fstypes: + bb.fatal('Unsupported image type built. Add a comptible image to ' + 'IMAGE_FSTYPES. Supported types: %s' % + ', '.join(supported_fstypes)) rootfs = '%s.%s' % (image_name, fstypes[0]) # Get tmpdir (not really used, just for compatibility)
Signature · 1 line
2.11.0
Quoted 25 lines · Aníbal Limón
When use simpleremote target the flash/boot process is executed manually, the
IMAGE_FSTYPESvalidation is only needed when execute testimage against qemu.The
supported_fstypescomes from oeqa.core.target.qemu module.Signed-off-by Aníbal Limón <[email protected]>--- meta/classes/testimage.bbclass | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-)meta/classes/testimage.bbclass +0
-6@@ -194,12 +194,13 @@ def testimage_main(d): machine = d.getVar("MACHINE") # Get rootfs - fstypes = [fs for fs in d.getVar('IMAGE_FSTYPES').split(' ') - if fs in supported_fstypes] - if not fstypes: - bb.fatal('Unsupported image type built. Add a comptible image to ' - 'IMAGE_FSTYPES. Supported types: %s' % - ', '.join(supported_fstypes))
meta/classes/testimage.bbclass def testimage_main(d): · line 206
Quoted 10 lines
meta/classes/testimage.bbclass +7
-0+ fstypes = d.getVar('IMAGE_FSTYPES') + if d.getVar("TEST_TARGET") == "qemu": + fstypes = [fs for fs in fstypes if fs in supported_fstypes] + if not fstypes: + bb.fatal('Unsupported image type built. Add a comptible image to ' + 'IMAGE_FSTYPES. Supported types: %s' % + ', '.join(supported_fstypes)) rootfs = '%s.%s' % (image_name, fstypes[0]) # Get tmpdir (not really used, just for compatibility)
This causes the autobuilder to break and there is a bug in the logic above:
https://autobuilder.yoctoproject.org/typhoon/#/builders/32/builds/128/steps/7/logs/step1c
(one of many failures as everything broke)
Cheers,
Richard
Quoted 38 lines · On Sat, 20 Oct 2018 at 02:11, <[email protected]> wrote:
Quoted 4 lines · Aníbal Limón
When use simpleremote target the flash/boot process is executed manually, the
IMAGE_FSTYPESvalidation is only needed when execute testimage against qemu.Review
Quoted 8 lines
The
supported_fstypescomes from oeqa.core.target.qemu module.Signed-off-by Aníbal Limón <[email protected]>--- meta/classes/testimage.bbclass | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-)(quoted diff) +0
-0b/meta/classes/testimage.bbclass
meta/classes/testimage.bbclass def testimage_main(d): · line 200
Quoted 11 lines
index
2642a722e7..734cb7caae100644meta/classes/testimage.bbclass +0
-4@@ -194,12 +194,13 @@ def testimage_main(d): machine = d.getVar("MACHINE") # Get rootfs - fstypes = [fs for fs in d.getVar('IMAGE_FSTYPES').split(' ') - if fs in supported_fstypes] - if not fstypes: - bb.fatal('Unsupported image type built. Add a comptible imageto '
meta/classes/testimage.bbclass def testimage_main(d):
Quoted 7 lines
meta/classes/testimage.bbclass +5
-2- 'IMAGE_FSTYPES. Supported types: %s' % - ', '.join(supported_fstypes)) + fstypes = d.getVar('IMAGE_FSTYPES') + if d.getVar("TEST_TARGET") == "qemu": + fstypes = [fs for fs in fstypes if fs in supported_fstypes] + if not fstypes: + bb.fatal('Unsupported image type built. Add a comptibleimage to '
Quoted 4 lines
meta/classes/testimage.bbclass +2
-0+ 'IMAGE_FSTYPES. Supported types: %s' % + ', '.join(supported_fstypes)) rootfs = '%s.%s' % (image_name, fstypes[0])
Quoted 7 lines
meta/classes/testimage.bbclass def testimage_main(d): · line 206
Quoted 1 line
meta/classes/testimage.bbclass +0
-0# Get tmpdir (not really used, just for compatibility)This causes the autobuilder to break and there is a bug in the logic above:
https://autobuilder.yoctoproject.org/typhoon/#/builders/32/builds/128/steps/7/logs/step1c
I'm not seeing this error, I executed testimage in qemuarm and qemux86, I'm looking at the configuration but should not fail because I added only a conditional to filter only
when the target is qemu.
Regards,
Anibal
Quoted 10 lines
(one of many failures as everything broke)
Cheers,
Richard
Quoted 4 lines · Anibal Limon
Quoted 4 lines
meta/classes/testimage.bbclass def testimage_main(d): · line 199
Quoted 4 lines
meta/classes/testimage.bbclass +2
-1- fstypes = [fs for fs in d.getVar('IMAGE_FSTYPES').split(' ') + fstypes = d.getVar('IMAGE_FSTYPES') + fstypes = [fs for fs in fstypes if fs in supported_fstypes]
That's the problem, the old code takes IMAGE_FSTYPES and splits it on whitespace, the new code iterates over each *character*
Ross
Quoted 10 lines · Ross
Quoted 4 lines · Anibal Limon
Quoted 4 lines
meta/classes/testimage.bbclass def testimage_main(d): · line 199
Quoted 4 lines
meta/classes/testimage.bbclass +2
-1- fstypes = [fs for fs in d.getVar('IMAGE_FSTYPES').split(' ') + fstypes = d.getVar('IMAGE_FSTYPES') + fstypes = [fs for fs in fstypes if fs in supported_fstypes]That's the problem, the old code takes
IMAGE_FSTYPESand splits it on whitespace, the new code iterates over each *character*
I sent an old version, sorry for that, sending v3...
Anibal
Quoted 3 lines
Ross