Re: Possible to combine ExclusiveArch?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, 2023-07-14 at 13:30 +0100, Richard W.M. Jones wrote:
> For some virt packages we need to combine 2 or 3 of:
> 
>   ExclusiveArch: %{kernel_arches}
>   ExclusiveArch: %{qemu_sysemu_host_arches}       # [1]
>   ExclusiveArch: %{ocaml_native_compiler}
> 
> to mean only compile on the intersection of these arches.  If you
> have
> multiple ExclusiveArch lines then RPM seems to do the union of arches
> which is the opposite of what anyone would want.

I beg to differ. When a tag in RPM can have multiple items (e.g.
Provides, (Build)Requires), this …:

Tag: item1 item2 item3

… is consistently equivalent to this:

Tag: item1
Tag: item2
Tag: item3

To have ExclusiveArch behave differently would be surprising – nobody
(😉) would read this and expect the effective list of arches the
package would be built for to be empty:

ExclusiveArch: x86_64
ExclusiveArch: s390x
ExclusiveArch: aarch64

> Dan Berrange came up with a clever way to do it though ...
> 
>   %ifnarch %{kernel_arches}
>   ExcludeArch: %{_arch}
>   %endif
>   %ifnarch %{qemu_sysemu_host_arches}
>   ExcludeArch: %{_arch}
>   %endif
> 
> But this makes my head hurt.  Is there a better way or could RPM
> provide explicit union and intersection operators?

I think this would be a good approach.


Nils
-- 
Nils Philippsen / Senior Software Engineer / Red Hat
PGP fingerprint: D0C1 1576 CDA6 5B6E BBAE 95B2 7D53 7FCA E9F6 395D
_______________________________________________
devel mailing list -- devel@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to devel-leave@xxxxxxxxxxxxxxxxxxxxxxx
Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/devel@xxxxxxxxxxxxxxxxxxxxxxx
Do not reply to spam, report it: https://pagure.io/fedora-infrastructure/new_issue




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Fedora Announce]     [Fedora Users]     [Fedora Kernel]     [Fedora Testing]     [Fedora Formulas]     [Fedora PHP Devel]     [Kernel Development]     [Fedora Legacy]     [Fedora Maintainers]     [Fedora Desktop]     [PAM]     [Red Hat Development]     [Gimp]     [Yosemite News]

  Powered by Linux