diff options
author | Piotr Kubaj <pkubaj@FreeBSD.org> | 2021-07-21 11:21:44 +0000 |
---|---|---|
committer | Piotr Kubaj <pkubaj@FreeBSD.org> | 2021-07-21 11:21:44 +0000 |
commit | 588ce0d6f952d06fab4406f2f58b99a33d321660 (patch) | |
tree | ee35ed76f16f479b9be9c6bd40fbc6dde8f512de | |
parent | 4642ccc60e9e00c2c50e57d419c9d402eda682e8 (diff) | |
download | ports-588ce0d6f952d06fab4406f2f58b99a33d321660.tar.gz ports-588ce0d6f952d06fab4406f2f58b99a33d321660.zip |
graphics/mesa-dri: fix build on powerpc64le
n file included from ../src/gallium/drivers/llvmpipe/lp_setup_tri.c:50:
/usr/lib/clang/11.0.1/include/altivec.h:55:19: error: unknown type name 'vector'
static __inline__ vector bool char __ATTRS_o_ai
^
/usr/lib/clang/11.0.1/include/altivec.h:56:10: error: unknown type name 'vector'
vec_perm(vector bool char __a, vector bool char __b, vector unsigned char __c);
^
/usr/lib/clang/11.0.1/include/altivec.h:56:32: error: unknown type name 'vector'
vec_perm(vector bool char __a, vector bool char __b, vector unsigned char __c);
^
/usr/lib/clang/11.0.1/include/altivec.h:66:19: error: unknown type name 'vector'
static __inline__ vector bool short __ATTRS_o_ai vec_perm(
^
/usr/lib/clang/11.0.1/include/altivec.h:67:5: error: unknown type name 'vector'
vector bool short __a, vector bool short __b, vector unsigned char __c);
^
/usr/lib/clang/11.0.1/include/altivec.h:67:28: error: unknown type name 'vector'
vector bool short __a, vector bool short __b, vector unsigned char __c);
^
/usr/lib/clang/11.0.1/include/altivec.h:80:19: error: unknown type name 'vector'
static __inline__ vector bool int __ATTRS_o_ai
^
/usr/lib/clang/11.0.1/include/altivec.h:81:10: error: unknown type name 'vector'
vec_perm(vector bool int __a, vector bool int __b, vector unsigned char __c);
^
/usr/lib/clang/11.0.1/include/altivec.h:81:31: error: unknown type name 'vector'
vec_perm(vector bool int __a, vector bool int __b, vector unsigned char __c);
^
/usr/lib/clang/11.0.1/include/altivec.h:96:19: error: unknown type name 'vector'
static __inline__ vector bool long long __ATTRS_o_ai
^
/usr/lib/clang/11.0.1/include/altivec.h:97:10: error: unknown type name 'vector'
vec_perm(vector bool long long __a, vector bool long long __b,
^
/usr/lib/clang/11.0.1/include/altivec.h:97:37: error: unknown type name 'vector'
vec_perm(vector bool long long __a, vector bool long long __b,
^
/usr/lib/clang/11.0.1/include/altivec.h:203:9: error: unknown type name 'vector'
vec_add(vector bool char __a, vector signed char __b) {
^
/usr/lib/clang/11.0.1/include/altivec.h:208:33: error: unknown type name 'vector'
vec_add(vector signed char __a, vector bool char __b) {
^
/usr/lib/clang/11.0.1/include/altivec.h:218:9: error: unknown type name 'vector'
vec_add(vector bool char __a, vector unsigned char __b) {
^
/usr/lib/clang/11.0.1/include/altivec.h:223:35: error: unknown type name 'vector'
vec_add(vector unsigned char __a, vector bool char __b) {
^
/usr/lib/clang/11.0.1/include/altivec.h:232:53: error: unknown type name 'vector'
static __inline__ vector short __ATTRS_o_ai vec_add(vector bool short __a,
^
/usr/lib/clang/11.0.1/include/altivec.h:238:53: error: unknown type name 'vector'
vector bool short __b) {
^
/usr/lib/clang/11.0.1/include/altivec.h:248:9: error: unknown type name 'vector'
vec_add(vector bool short __a, vector unsigned short __b) {
^
fatal error: too many errors emitted, stopping now [-ferror-limit=]
20 errors generated.
Additionally, fix packaging failure on all powerpc*, since llvmpipe is now used.
3 files changed, 25 insertions, 1 deletions
diff --git a/graphics/mesa-dri/Makefile b/graphics/mesa-dri/Makefile index c0ce8fb7e6af..c612fc0e7f39 100644 --- a/graphics/mesa-dri/Makefile +++ b/graphics/mesa-dri/Makefile @@ -39,7 +39,7 @@ DRI_DRIVERS+= R100 .endif .if ${ARCH} == aarch64 || ${ARCH} == amd64 || ${ARCH} == i386 \ - || ${ARCH} == powerpc || ${ARCH} == powerpc64 + || ${ARCH:Mpowerpc*} DRI_DRIVERS+= R100 R200 GALLIUM_DRIVERS+= R300 R600 RADEONSI VULKAN_DRIVERS+= AMD diff --git a/graphics/mesa-dri/files/patch-src_gallium_drivers_llvmpipe_lp__rast__tri.c b/graphics/mesa-dri/files/patch-src_gallium_drivers_llvmpipe_lp__rast__tri.c new file mode 100644 index 000000000000..c4a658ce2c62 --- /dev/null +++ b/graphics/mesa-dri/files/patch-src_gallium_drivers_llvmpipe_lp__rast__tri.c @@ -0,0 +1,12 @@ +--- src/gallium/drivers/llvmpipe/lp_rast_tri.c.orig 2021-07-21 11:06:08 UTC ++++ src/gallium/drivers/llvmpipe/lp_rast_tri.c +@@ -465,7 +465,9 @@ lp_rast_triangle_32_3_4(struct lp_rasterizer_task *tas + + #if defined(_ARCH_PWR8) && UTIL_ARCH_LITTLE_ENDIAN + ++#undef bool + #include <altivec.h> ++#define bool _Bool + #include "util/u_pwr8.h" + + static inline void diff --git a/graphics/mesa-dri/files/patch-src_gallium_drivers_llvmpipe_lp__setup__tri.c b/graphics/mesa-dri/files/patch-src_gallium_drivers_llvmpipe_lp__setup__tri.c new file mode 100644 index 000000000000..8d9f88e80e1d --- /dev/null +++ b/graphics/mesa-dri/files/patch-src_gallium_drivers_llvmpipe_lp__setup__tri.c @@ -0,0 +1,12 @@ +--- src/gallium/drivers/llvmpipe/lp_setup_tri.c.orig 2021-07-21 11:05:23 UTC ++++ src/gallium/drivers/llvmpipe/lp_setup_tri.c +@@ -47,7 +47,9 @@ + #if defined(PIPE_ARCH_SSE) + #include <emmintrin.h> + #elif defined(_ARCH_PWR8) && UTIL_ARCH_LITTLE_ENDIAN ++#undef bool + #include <altivec.h> ++#define bool _Bool + #include "util/u_pwr8.h" + #endif + |