Bug 1298668 - Allow noarch builds with ExclusiveArch not containing noarch [NEEDINFO]
Allow noarch builds with ExclusiveArch not containing noarch
Status: CLOSED RAWHIDE
Product: Fedora
Classification: Fedora
Component: rpm (Show other bugs)
24
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: packaging-team-maint
Fedora Extras Quality Assurance
http://rpm.org/ticket/901
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2016-01-14 12:21 EST by Orion Poplawski
Modified: 2016-11-14 10:16 EST (History)
11 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-04-06 10:31:14 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
praiskup: needinfo? (packaging-team-maint)


Attachments (Terms of Use)

  None (edit)
Description Orion Poplawski 2016-01-14 12:21:30 EST
Description of problem:

If you have:

BuildArch?: noarch
ExclusiveArch?: x86_64

You get:

$ rpmbuild -ba *spec
error: Architecture is not included: noarch

Since there are no "noarch" machines, it seems useful to special case noarch builds. This would save a lot of grief with the koji builders and trying to limit noarch builds to certain architectures.

Version-Release number of selected component (if applicable):
rpm-4.13.0-0.rc1.13.fc24.x86_64
Comment 1 Orion Poplawski 2016-01-14 12:23:43 EST
See https://fedoraproject.org/wiki/Packaging:Guidelines#Noarch_with_unported_dependencies for some backgound.
Comment 2 Jan Kurik 2016-02-24 09:17:21 EST
This bug appears to have been reported against 'rawhide' during the Fedora 24 development cycle.
Changing version to '24'.

More information and reason for this action is here:
https://fedoraproject.org/wiki/Fedora_Program_Management/HouseKeeping/Fedora24#Rawhide_Rebase
Comment 3 Florian Festi 2016-02-26 03:12:22 EST
While we could make an exception for noarch in the code I am wondering if this really is the right thing to do. Why would you only add ExclusiveArch?: x86_64 to a noarch package? Why not just add noarch to that line?

May be I am not really getting the use case...
Comment 4 Michael Mráka 2016-02-26 03:40:52 EST
The use case is:
The built package is noarch but it has a BuildRequires which is arched (e.g  for documentation build process).
And that BuildRequires is available only on x86_64 so builds on s390x builders constantly fail.
On the other hand the final package runs on s390x just fine.
Comment 5 Florian Festi 2016-02-26 05:33:36 EST
Ok I have a fix upstream as https://github.com/rpm-software-management/rpm/commit/d53499d1565dd7ba6d93939e552cc604b26dccd7 which is also in rpm-4.13.0-0.rc1.26.fc25 .

I am still not 100% sure this doesn't create any additional problems. But I really have no clue what releng in all of the different distros actually does - especially with ExcludeArch/ExclusiveArch. Please test thoroughly! I really would avoid things like breaking the build sys for all noarch packages.

Also note that this change won't make it into F24 until  someone assures me that it won't break the build system.
Comment 6 Florian Festi 2016-03-30 06:28:57 EDT
Does that patch fix your issue? And not break anything else?
Comment 7 Orion Poplawski 2016-03-30 13:29:37 EDT
It seems fine.  koji will still need to get changed to really allow it to be exercised, but I think it's a step in the right direction and hasn't caused any problems that I'm aware of.  Thanks.
Comment 8 Florian Festi 2016-04-06 03:43:35 EDT
Do you need this to be back ported to F24 or even F23? Or can we just close it as fixed?
Comment 9 Orion Poplawski 2016-04-06 10:31:14 EDT
At the moment lets just close it as fixed.  There are koji changes that would need to be made as well to get it into production.
Comment 10 Ralph Bean 2016-09-30 14:10:02 EDT
Tracking koji changes here:  https://pagure.io/koji/issue/19
Comment 11 Pavel Raiskup 2016-11-14 09:58:11 EST
(In reply to Florian Festi from comment #8)
> Do you need this to be back ported to F24 or even F23? Or can we just close
> it as fixed?

I would actually vote to have it fixed F23+.  Otherwise the
'ExclusiveArch: ...' + 'BuildArch: noarch' hack doesn't work at all
in pungi: https://pagure.io/pungi-fedora/issue/87

Long story short -> when you put 'noarch' into ExclusiveArch tag, every
_binary_ RPM ((sub)package) instantiated from the spec file "inherits"
this 'noarch' bit from _source_ RPM and then is "compatible" (from the
pungi POV) with every Fedora compatible architecture.

Note You need to log in before you can comment on or make changes to this bug.