manifest.py: fix test_SDK_manifest_entries
cover manifest.py: fix test_SDK_manifest_entries
*** BLURB HERE ***
The following changes since commit 27d60c5a812774f0e5c43161e5b514c4aebdf301:
gstreamer1.0-libav: disable API documentation (2019-06-15 13:46:38 +0100)
are available in the git repository at:
git://git.pokylinux.org/poky-contrib ChenQi/oeqa-manifest
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=ChenQi/oeqa-manifest
Chen Qi (1):
manifest.py: fix test_SDK_manifest_entries
meta/lib/oeqa/selftest/cases/manifest.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-)
Signature · 1 line
1.9.1
PATCH 1/1 manifest.py: fix test_SDK_manifest_entries
TOOLCHAIN_OUTPUTNAME could be overridden. So use this variable directly instead of its default value ${SDK_NAME}-toolchain-${SDK_VERSION}.
--- meta/lib/oeqa/selftest/cases/manifest.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-)
meta/lib/oeqa/selftest/cases/manifest.py +2 -5
@@ -86,11 +86,8 @@ class VerifyManifest(OESelftestTestCase): try: mdir = self.get_dir_from_bb_var('SDK_DEPLOY', self.buildtarget) for k in d_target.keys(): - bb_vars = get_bb_vars(['SDK_NAME', 'SDK_VERSION'], self.buildtarget) - mfilename[k] = "{}-toolchain-{}.{}.manifest".format( - bb_vars['SDK_NAME'], - bb_vars['SDK_VERSION'], - k) + toolchain_outputname = get_bb_var('TOOLCHAIN_OUTPUTNAME', self.buildtarget) + mfilename[k] = "{}.{}.manifest".format(toolchain_outputname, k) mpath[k] = os.path.join(mdir, mfilename[k]) if not os.path.isfile(mpath[k]): self.logger.debug("{}: {} does not exist".format(
Signature · 1 line
1.9.1
Quoted 13 lines · Chen Qi
TOOLCHAIN_OUTPUTNAMEcould be overridden. So use this variable directly instead of its default value ${SDK_NAME}-toolchain-${SDK_VERSION}.Signed-off-by Chen Qi <[email protected]>--- meta/lib/oeqa/selftest/cases/manifest.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-)meta/lib/oeqa/selftest/cases/manifest.py +0
-0
meta/lib/oeqa/selftest/cases/manifest.py class VerifyManifest(OESelftestTestCase): · line 90
Quoted 10 lines
meta/lib/oeqa/selftest/cases/manifest.py +2
-5@@ -86,11 +86,8 @@ class VerifyManifest(OESelftestTestCase): try: mdir = self.get_dir_from_bb_var('SDK_DEPLOY', self.buildtarget) for k in d_target.keys(): - bb_vars = get_bb_vars(['SDK_NAME', 'SDK_VERSION'], self.buildtarget) - mfilename[k] = "{}-toolchain-{}.{}.manifest".format( - bb_vars['SDK_NAME'], - bb_vars['SDK_VERSION'], - k) + toolchain_outputname = get_bb_var('TOOLCHAIN_OUTPUTNAME', self.buildtarget) + mfilename[k] = "{}.{}.manifest".format(toolchain_outputname, k)
Whilst I agree there is a problem here, this code is iterating over multiple targets. Isn't TOOLCHAIN_OUTPUTNAME only going to be correct for one of them?
Cheers,
Richard
Quoted 28 lines · Richard Purdie
Quoted 13 lines · Chen Qi
TOOLCHAIN_OUTPUTNAMEcould be overridden. So use this variable directly instead of its default value ${SDK_NAME}-toolchain-${SDK_VERSION}.Signed-off-by Chen Qi <[email protected]>--- meta/lib/oeqa/selftest/cases/manifest.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-)meta/lib/oeqa/selftest/cases/manifest.py +0
-0meta/lib/oeqa/selftest/cases/manifest.py class VerifyManifest(OESelftestTestCase): · line 90
Quoted 10 lines
meta/lib/oeqa/selftest/cases/manifest.py +2
-5@@ -86,11 +86,8 @@ class VerifyManifest(OESelftestTestCase): try: mdir = self.get_dir_from_bb_var('SDK_DEPLOY', self.buildtarget) for k in d_target.keys(): - bb_vars = get_bb_vars(['SDK_NAME', 'SDK_VERSION'], self.buildtarget) - mfilename[k] = "{}-toolchain-{}.{}.manifest".format( - bb_vars['SDK_NAME'], - bb_vars['SDK_VERSION'], - k) + toolchain_outputname = get_bb_var('TOOLCHAIN_OUTPUTNAME', self.buildtarget) + mfilename[k] = "{}.{}.manifest".format(toolchain_outputname, k)Whilst I agree there is a problem here, this code is iterating over multiple targets. Isn't
TOOLCHAIN_OUTPUTNAMEonly going to be correct for one of them?
Quoted 5 lines
Cheers,
Richard
This code is iterating over d_target.keys(), which is 'target' and 'host'. And the TOOLCHAIN_OUTPUTNAME is for self.buildtarget, which is core-image-minimal. Thus, we are basically checking ${TOOLCHAIN_OUTPUTNAME}.target.manifest and ${TOOLCHAIN_OUTPUTNAME}.host.target. e.g.
tmp-glibc/deploy/sdk/poky-glibc-x86_64-core-image-minimal-core2-64-qemux86-64-toolchain-2.7+snapshot.host.manifest tmp-glibc/deploy/sdk/poky-glibc-x86_64-core-image-minimal-core2-64-qemux86-64-toolchain-2.7+snapshot.target.manifest
So I think things are correct.
Best Regards,
Chen Qi
Quoted 56 lines · ChenQi
Quoted 37 lines · Richard Purdie
Quoted 28 lines · Chen Qi
TOOLCHAIN_OUTPUTNAMEcould be overridden. So use this variable directly
instead of its default value ${SDK_NAME}-toolchain- ${SDK_VERSION}.Signed-off-by Chen Qi <[email protected]>--- meta/lib/oeqa/selftest/cases/manifest.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-)meta/lib/oeqa/selftest/cases/manifest.py +0
-2@@ -86,11 +86,8 @@ class VerifyManifest(OESelftestTestCase): try: mdir = self.get_dir_from_bb_var('SDK_DEPLOY', self.buildtarget) for k in d_target.keys(): - bb_vars = get_bb_vars(['SDK_NAME', 'SDK_VERSION'], self.buildtarget) - mfilename[k] = "{}-toolchain-{}.{}.manifest".format(
meta/lib/oeqa/selftest/cases/manifest.py +1
-3- bb_vars['SDK_NAME'], - bb_vars['SDK_VERSION'], - k) + toolchain_outputname =Quoted 3 lines
get_bb_var('TOOLCHAIN_OUTPUTNAME', self.buildtarget)
+ mfilename[k] =
"{}.{}.manifest".format(toolchain_outputname, k)Whilst I agree there is a problem here, this code is iterating over multiple targets. Isn't
TOOLCHAIN_OUTPUTNAMEonly going to be correct
for one of them?Quoted 5 lines
Cheers,
Richard
This code is iterating over
d_target.keys(), which is 'target' and 'host'. And theTOOLCHAIN_OUTPUTNAMEis for self.buildtarget, which is
core-image-minimal. Thus, we are basically checking ${TOOLCHAIN_OUTPUTNAME}.target.manifest and ${TOOLCHAIN_OUTPUTNAME}.host.target.
e.g. tmp-glibc/deploy/sdk/poky-glibc-x86_64-core-image-minimal-core2-64- qemux86-64-toolchain-2.7+snapshot.host.manifest tmp-glibc/deploy/sdk/poky-glibc-x86_64-core-image-minimal-core2-64- qemux86-64-toolchain-2.7+snapshot.target.manifest
Quoted 1 line
So I think things are correct.
You're right, I was going from memory and thought this code was handling the case where there are two different targets in an SDK (e.g. a multilib) but that isn't the case. I've queued the patch for testing.
Cheers,
Richard