blob: 220583d578efd397d5a1f24a3b04b6a8430a5296 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
|
qemu 8.1.0 fails to build with ppc64l and musl libc
Description of problem:
qemu 8.1.0 fails to build on alpine linux ppc64le:
```
ninja: job failed: gcc -m64 -mlittle-endian -Ilibqemuutil.a.p -I. -I.. -Iqapi -Itrace -Iui/shader -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -fdiagnostics-color=auto -Wall -Winvalid-pch -std=gnu11 -O2 -fstack-protector-strong -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -Wundef -Wwrite-strings -Wmissing-prototypes -Wstrict-prototypes -Wredundant-decls -Wold-style-declaration -Wold-style-definition -Wtype-limits -Wformat-security -Wformat-y2k -Winit-self -Wignored-qualifiers -Wempty-body -Wnested-externs -Wendif-labels -Wexpansion-to-defined -Wimplicit-fallthrough=2 -Wmissing-format-attribute -Wno-missing-include-dirs -Wno-shift-negative-value -Wno-psabi -isystem /home/ncopa/aports/community/qemu/src/qemu-8.1.0/linux-headers -isystem linux-headers -iquote . -iquote /home/ncopa/aports/community/qemu/src/qemu-8.1.0 -iquote /home/ncopa/aports/community/qemu/src/qemu-8.1.0/include -iquote /home/ncopa/aports/community/qemu/src/qemu-8.1.0/host/include/ppc64 -iquote /home/ncopa/aports/community/qemu/src/qemu-8.1.0/host/include/generic -iquote /home/ncopa/aports/community/qemu/src/qemu-8.1.0/tcg/ppc -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -fno-strict-aliasing -fno-common -fwrapv -Os -fstack-clash-protection -Wformat -Werror=format-security -O2 -fPIE -pthread -MD -MQ libqemuutil.a.p/util_cpuinfo-ppc.c.o -MF libqemuutil.a.p/util_cpuinfo-ppc.c.o.d -o libqemuutil.a.p/util_cpuinfo-ppc.c.o -c ../util/cpuinfo-ppc.c
../util/cpuinfo-ppc.c: In function 'cpuinfo_init':
../util/cpuinfo-ppc.c:33:18: error: 'PPC_FEATURE2_ARCH_3_1' undeclared (first use in this function); did you mean 'PPC_FEATURE2_ARCH_3_00'?
33 | if (hwcap2 & PPC_FEATURE2_ARCH_3_1) {
| ^~~~~~~~~~~~~~~~~~~~~
| PPC_FEATURE2_ARCH_3_00
../util/cpuinfo-ppc.c:33:18: note: each undeclared identifier is reported only once for each function it appears in
../util/cpuinfo-ppc.c:43:18: error: 'PPC_FEATURE2_HAS_ISEL' undeclared (first use in this function); did you mean 'PPC_FEATURE_HAS_VSX'?
43 | if (hwcap2 & PPC_FEATURE2_HAS_ISEL) {
| ^~~~~~~~~~~~~~~~~~~~~
| PPC_FEATURE_HAS_VSX
../util/cpuinfo-ppc.c:56:26: error: 'PPC_FEATURE2_HAS_VEC_CRYPTO' undeclared (first use in this function); did you mean 'PPC_FEATURE2_VEC_CRYPTO'?
56 | if (hwcap2 & PPC_FEATURE2_HAS_VEC_CRYPTO) {
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
| PPC_FEATURE2_VEC_CRYPTO
ninja: subcommand failed
make: *** [Makefile:162: run-ninja] Error 1
```
Steps to reproduce:
Build qemu 8.1.0 on alpine linux ppc64le.
Additional information:
Likely introduced by 623d7e3551a6fc5693c06ea938c60fe281b52e27
Explicit `#include <asm/cputable.h>` fixes the `PPC_FEATURE2_ARCH_3_1` case but not the other two.
|