1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-25 04:43:33 +00:00

graphics/libglvnd: fix build on powerpc64

While the previous fix works on powerpc64le, it looks like on powerpc64
clang is misoptimizing the code, needing -O0:
cc -Isrc/util/libcJSON.a.p -Isrc/util -I../src/util -fvisibility=hidden -fno-color-diagnostics -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -std=gnu99 -O3 -DUSE_PPC64_ASM -DENABLE_EGL_X11 -DHAVE_TYPEOF -DGLDISPATCH_USE_TLS -DUSE_DISPATCH_ASM -DUSE_ATTRIBUTE_CONSTRUCTOR -DHAVE_PTHREAD_RWLOCK -DHAVE_SYNC_INTRINSICS -DHAVE_MINCORE -DHAVE_RTLD_NOLOAD -DHAVE_DIRENT_DTYPE -DGLDISPATCH_ENABLE_PATCHING -DEGL_NO_X11 -O2 -pipe -no-integrated-as -fstack-protector-strong -isystem /usr/local/include -fno-strict-aliasing -isystem /usr/local/include -fPIC -MD -MQ src/util/libcJSON.a.p/cJSON.c.o -MF src/util/libcJSON.a.p/cJSON.c.o.d -o src/util/libcJSON.a.p/cJSON.c.o -c ../src/util/cJSON.c
/tmp/cJSON-528d5f.s: Assembler messages:
/tmp/cJSON-528d5f.s:327: Error: unrecognized opcode: `vxor'
/tmp/cJSON-528d5f.s:337: Error: unrecognized opcode: `stvx'
/tmp/cJSON-528d5f.s:339: Error: unrecognized opcode: `stvx'
/tmp/cJSON-528d5f.s:340: Error: unrecognized opcode: `stvx'
/tmp/cJSON-528d5f.s:1507: Error: unrecognized opcode: `vxor'
/tmp/cJSON-528d5f.s:1515: Error: unrecognized opcode: `stvx'
/tmp/cJSON-528d5f.s:1517: Error: unrecognized opcode: `stvx'
/tmp/cJSON-528d5f.s:1519: Error: unrecognized opcode: `stvx'
/tmp/cJSON-528d5f.s:1520: Error: unrecognized opcode: `stvx'
/tmp/cJSON-528d5f.s:1937: Error: unrecognized opcode: `lvx'
/tmp/cJSON-528d5f.s:1940: Error: unrecognized opcode: `lvx'
/tmp/cJSON-528d5f.s:1942: Error: unrecognized opcode: `vspltb'
/tmp/cJSON-528d5f.s:1948: Error: unrecognized opcode: `lvx'
/tmp/cJSON-528d5f.s:1950: Error: unrecognized opcode: `lvx'
/tmp/cJSON-528d5f.s:1951: Error: unrecognized opcode: `lvsl'
/tmp/cJSON-528d5f.s:1952: Error: unrecognized opcode: `vperm'
/tmp/cJSON-528d5f.s:1953: Error: unrecognized opcode: `vcmpequb'
/tmp/cJSON-528d5f.s:1954: Error: unrecognized opcode: `vsel'
/tmp/cJSON-528d5f.s:1955: Error: unrecognized opcode: `stvx'
/tmp/cJSON-528d5f.s:2314: Error: unrecognized opcode: `vxor'
/tmp/cJSON-528d5f.s:2321: Error: unrecognized opcode: `stvx'
/tmp/cJSON-528d5f.s:2323: Error: unrecognized opcode: `stvx'
/tmp/cJSON-528d5f.s:2325: Error: unrecognized opcode: `stvx'
/tmp/cJSON-528d5f.s:2327: Error: unrecognized opcode: `stvx'
cc: error: assembler command failed with exit code 1 (use -v to see invocation)
This commit is contained in:
Piotr Kubaj 2022-02-22 08:33:42 +00:00
parent a245588319
commit a8e4b7a7e4

View File

@ -27,9 +27,12 @@ X11_MESON_ENABLED= x11 glx
.include <bsd.port.options.mk>
.if ${ARCH:Mpowerpc64*}
.if ${ARCH} == powerpc64le
BUILD_DEPENDS= as:devel/binutils
CFLAGS+= -no-integrated-as
.elif ${ARCH} == powerpc64
BUILD_DEPENDS= as:devel/binutils
CFLAGS+= -no-integrated-as -O0
.endif
# Lots of software expects gl.pc even when it can build with EGL only