W dniu 2.09.2023 o 20:11, Liviu Ionescu pisze:
When trying to build 8.1.0 on an Ubuntu 18.04 aarch64, I get the
above error.

Ubuntu 18.04 is not supported anymore by Canonical. End-Of-Life was in
May 2023.

The offending code in `/util/cpuinfo-aarch64.c` is:

> ```c
> #ifdef CONFIG_LINUX
>      unsigned long hwcap = qemu_getauxval(AT_HWCAP);
>      info |= (hwcap & HWCAP_ATOMICS ? CPUINFO_LSE : 0);
>      info |= (hwcap & HWCAP_USCAT ? CPUINFO_LSE2 : 0);
>      info |= (hwcap & HWCAP_AES ? CPUINFO_AES: 0);
> #endif
> ```

The reason is that on this distribution the <bits/hwcap.h> header
file does not define HWCAP_USCAT:

I would recommend either upgrading your distro or staying at QEMU 8.1
release.

HWCAP_USCAT was added to glibc in June 2018. As your distribution is not supported anymore you can also patch glibc in your system.

I don't know if other distributions are also affected, my build
platform for all xPack standalone binaries is Ubuntu 18.04 LTS.

I do not know any supported distribution release without it.

I know that 18.04 is an old version, but I use the xPack QEMU mainly
to run unit tests, and in some enterprise environments the machines
used for testing are sometimes pretty outdated, thus 18.04 will
remain the base build platform for a while.

It would be very nice if QEMU would still compile on Ubuntu 18.04, as
it did before 8.1.0.

Reply via email to