How to build noarch package on only certain architectures?

Richard W.M. Jones rjones at redhat.com
Tue May 17 15:43:47 UTC 2011


On Tue, May 17, 2011 at 09:33:51AM -0400, Josh Boyer wrote:
> On Tue, May 17, 2011 at 9:28 AM, Kevin Fenzi <kevin at scrye.com> wrote:
> >> Is there some other way to add a noarch package that doesn't build on
> >> some architectures?
> >
> > Sadly this is a nasty situation. (I'm in the same boat with munin).
> >
> > There are 2 answers, neither ideal (I'd love to hear better):
> >
> > 1. Make your package archfull. Add ExcludeArch/ExclusiveArch.
> >
> > 2. Leave it noarch and ExcludeArch: ppc64, then try and keep rebuilding
> > it until you hit a non ppc builder.
> 
> 3. See if you can modify the package to do runtime determinism of
> whether the dependency is there, and only use that functionality if
> it's present.  Personally I think that if that can't be done, then
> option 1 is the right way to go.

4. Post a patch to fix RPM.

This is a bug or shortcoming in RPM.  It affected some mingw32
packages as well IIRC -- they are noarch and can be built anywhere,
but we wanted to %check them using wine which only runs on i386.

Rich.

-- 
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
virt-df lists disk usage of guests without needing to install any
software inside the virtual machine.  Supports Linux and Windows.
http://et.redhat.com/~rjones/virt-df/


More information about the devel mailing list