On Sat, Dec 5, 2020 at 2:15 PM Simon Matter simon.matter@invoca.ch wrote:
Hi,
We are thinking about adding ARM64 based devices to our systems.
As we are using CentOS almost everywhere and have quite a number of inhouse RPM packages in our company repository, we'd like to enhance it and add ARM64 alias aarch64 to it.
What I'm still wondering is how to run the build environment for the new arch?
How does the CentOS project do it, run ARM64 hardware or using emulation? Or to ask differently, is it an option to run the build system emulated with QEMU?
Thanks for any insights?
The Mock tool from Fedora EPEL supports automatically running emulation for foreign architectures for building packages if qemu-user-static is installed. That makes building AArch64 packages from x86_64 or vice versa pretty simple.
To build a package for aarch64 from x86_64 from a fresh system using Mock:
$ sudo dnf install mock qemu-user-static $ sudo usermod -a -G mock $USER $ newgrp mock $ mock -r epel-8-aarch64 </path/to/package.src.rpm>
-- 真実はいつも一つ!/ Always, there's only one truth!