From be81aeaa7d2169985910b024c023a819d2360d8d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lubom=C3=ADr=20Sedl=C3=A1=C5=99?= Date: Fri, 14 Sep 2018 13:27:39 +0200 Subject: [PATCH] gather: Filter arches similarly to pkgset MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit There should not be multilib arches when checking if noarch package is compatible with current arch. Otherwise we might be excluding a package from x86_64 just because it does not work on i686. JIRA: COMPOSE-2885 Signed-off-by: Lubomír Sedlář --- pungi/phases/gather/sources/source_module.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pungi/phases/gather/sources/source_module.py b/pungi/phases/gather/sources/source_module.py index eb6008f5..04299f23 100644 --- a/pungi/phases/gather/sources/source_module.py +++ b/pungi/phases/gather/sources/source_module.py @@ -52,6 +52,9 @@ class GatherSourceModule(pungi.phases.gather.source.GatherSourceBase): compatible_arches = pungi.arch.get_compatible_arches(arch, multilib=True) multilib_arches = set(compatible_arches) - set( pungi.arch.get_compatible_arches(arch)) + exclusivearchlist = pungi.arch.get_valid_arches( + arch, multilib=False, add_noarch=False + ) # Generate architecture specific modulemd metadata, so we can # store per-architecture artifacts there later. @@ -78,7 +81,7 @@ class GatherSourceModule(pungi.phases.gather.source.GatherSourceBase): log.write('Examining %s for inclusion\n' % rpm_obj) # Skip the RPM if it is excluded on this arch or exclusive # for different arch. - if pungi.arch.is_excluded(rpm_obj, compatible_arches): + if pungi.arch.is_excluded(rpm_obj, exclusivearchlist): log.write('Skipping %s due to incompatible arch\n' % rpm_obj) continue