On Thu, Aug 08, 2019 at 04:22:33PM +0200, Paolo Bonzini wrote: > On 08/08/19 16:14, Richard W.M. Jones wrote: > > I'm trying to package OpenSBI RISC-V firmware for Fedora > > (https://github.com/riscv/opensbi). It's a similar situation to > > SeaBIOS and other architecture firmware. We have to cross-compile a > > binary on potentially any Koji architecture, and end up with a noarch > > package, because the final firmware blob can be installed on any > > architecture too. > > > > Here's my initial attempt: > > > > https://koji.fedoraproject.org/koji/taskinfo?taskID=36861731 > > http://oirase.annexia.org/reviews/opensbi/opensbi.spec > > > > I needed to use %global _binaries_in_noarch_packages_terminate_build 0 > > to stop RPM complaining about: > > > > error: Arch dependent binaries in noarch package > > > > SeaBIOS uses the same workaround: > > > > https://src.fedoraproject.org/rpms/seabios/blob/master/f/seabios.spec > > > > But also it builds an empty seabios package and then builds the binary > > into seabios-bin. Does anyone remember why that was needed? > > It's just backwards compatibility. seabios is a noarch package because > you can use it to run emulated x86 virtual machines on non-x86 > architectures. At the same time, we wanted the build to happen on an > x86 machine so that was done via the empty package + ExclusiveArch. > > Fedora builds of seabios and other firmware support cross compilation > these days though, so you don't need the hack anymore. You only need to > allow arch dependent binaries in noarch packages. Also, please install > the binaries in /usr/share, not /usr/lib. If it is just backwards compat, how about we kill the -bin RPM now to make it clearer to understand Regards, Daniel -- |: https://berrange.com -o- https://www.flickr.com/photos/dberrange :| |: https://libvirt.org -o- https://fstop138.berrange.com :| |: https://entangle-photo.org -o- https://www.instagram.com/dberrange :| _______________________________________________ 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