32-bit powerpc graphics/mesa-dri build failure (poudriere based): "error: cannot redeclare builtin function" (e.g., __sync_add_and_fetch_8)

Mark Millard via freebsd-ppc <[email protected]>
Newsgroups gmane.os.freebsd.devel.ppc,gmane.os.freebsd.devel.ports
Message-ID <[email protected]>
The error report material was:

cc -Isrc/util/ed6d25d@@mesa_util@sta -Isrc/util -I../src/util -Iinclude -I../include -Isrc -I../src -Isrc/mapi -I../src/mapi -Isrc/mesa -I../src/mesa -I../src/gallium/include -Isrc/gallium/auxiliary -
I../src/gallium/auxiliary -Xclang -fcolor-diagnostics -pipe -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -std=c99 -g -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS '-DPACKAGE_VERS
ION="19.0.8"' '-DPACKAGE_BUGREPORT="https://bugs.freedesktop.org/enter_bug.cgi?product=Mesa"' -DENABLE_ST_OMX_BELLAGIO=0 -DENABLE_ST_OMX_TIZONIA=0 -DHAVE_X11_PLATFORM -DGLX_INDIRECT_RENDERING -DGLX_DI
RECT_RENDERING -DGLX_USE_DRM -DHAVE_DRM_PLATFORM -DHAVE_SURFACELESS_PLATFORM -DDEBUG -DENABLE_SHADER_CACHE -DHAVE___BUILTIN_BSWAP32 -DHAVE___BUILTIN_BSWAP64 -DHAVE___BUILTIN_CLZ -DHAVE___BUILTIN_CLZLL
 -DHAVE___BUILTIN_CTZ -DHAVE___BUILTIN_EXPECT -DHAVE___BUILTIN_FFS -DHAVE___BUILTIN_FFSLL -DHAVE___BUILTIN_POPCOUNT -DHAVE___BUILTIN_POPCOUNTLL -DHAVE___BUILTIN_UNREACHABLE -DHAVE_FUNC_ATTRIBUTE_CONST
 -DHAVE_FUNC_ATTRIBUTE_FLATTEN -DHAVE_FUNC_ATTRIBUTE_MALLOC -DHAVE_FUNC_ATTRIBUTE_PURE -DHAVE_FUNC_ATTRIBUTE_UNUSED -DHAVE_FUNC_ATTRIBUTE_WARN_UNUSED_RESULT -DHAVE_FUNC_ATTRIBUTE_WEAK -DHAVE_FUNC_ATTR
IBUTE_FORMAT -DHAVE_FUNC_ATTRIBUTE_PACKED -DHAVE_FUNC_ATTRIBUTE_RETURNS_NONNULL -DHAVE_FUNC_ATTRIBUTE_VISIBILITY -DHAVE_FUNC_ATTRIBUTE_ALIAS -DHAVE_FUNC_ATTRIBUTE_NORETURN -D_GNU_SOURCE -DUSE_GCC_ATOM
IC_BUILTINS -DMISSING_64BIT_ATOMICS -DHAVE_SYS_SYSCTL_H -DHAVE_XLOCALE_H -DHAVE_DLFCN_H -DHAVE_STRTOF -DHAVE_MKOSTEMP -DHAVE_POSIX_MEMALIGN -DHAVE_TIMESPEC_GET -DHAVE_MEMFD_CREATE -DHAVE_STRTOD_L -DHA
VE_DLADDR -DHAVE_DL_ITERATE_PHDR -DHAVE_ZLIB -DHAVE_PTHREAD -DHAVE_LIBDRM -DHAVE_LLVM=0x0800 -DMESA_LLVM_VERSION_PATCH=1 -DHAVE_WAYLAND_PLATFORM -DWL_HIDE_DEPRECATED -DHAVE_DRI3 -DHAVE_DRI3_MODIFIERS 
-Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=return-type -fno-math-errno -fno-trapping-math -Qunused-arguments -Wno-missing-field-initializers -O2 -g -fstack-protector-stro
ng -fno-strict-aliasing -fPIC -pthread -Werror=pointer-arith -Werror=vla -fvisibility=hidden -MD -MQ 'src/util/ed6d25d@@mesa_util@sta/u_atomic.c.o' -MF 'src/util/ed6d25d@@mesa_util@sta/u_atomic.c.o.d'
 -o 'src/util/ed6d25d@@mesa_util@sta/u_atomic.c.o' -c ../src/util/u_atomic.c
../src/util/u_atomic.c:38:1: error: cannot redeclare builtin function '__sync_add_and_fetch_8'
__sync_add_and_fetch_8(uint64_t *ptr, uint64_t val)
^
../src/util/u_atomic.c:38:1: note: '__sync_add_and_fetch_8' is a builtin with type 'long long (volatile long long *, long long, ...)'
../src/util/u_atomic.c:38:1: error: definition of builtin function '__sync_add_and_fetch_8'
__sync_add_and_fetch_8(uint64_t *ptr, uint64_t val)
^
../src/util/u_atomic.c:51:1: error: cannot redeclare builtin function '__sync_sub_and_fetch_8'
__sync_sub_and_fetch_8(uint64_t *ptr, uint64_t val)
^
../src/util/u_atomic.c:51:1: note: '__sync_sub_and_fetch_8' is a builtin with type 'long long (volatile long long *, long long, ...)'
../src/util/u_atomic.c:51:1: error: definition of builtin function '__sync_sub_and_fetch_8'
__sync_sub_and_fetch_8(uint64_t *ptr, uint64_t val)
^
../src/util/u_atomic.c:64:1: error: cannot redeclare builtin function '__sync_val_compare_and_swap_8'
__sync_val_compare_and_swap_8(uint64_t *ptr, uint64_t oldval, uint64_t newval)
^
../src/util/u_atomic.c:64:1: note: '__sync_val_compare_and_swap_8' is a builtin with type 'long long (volatile long long *, long long, long long, ...)'
../src/util/u_atomic.c:64:1: error: definition of builtin function '__sync_val_compare_and_swap_8'
__sync_val_compare_and_swap_8(uint64_t *ptr, uint64_t oldval, uint64_t newval)
^
6 errors generated.

# poudriere jail -l
JAILNAME      VERSION      ARCH              METHOD TIMESTAMP           PATH
FBSDpowerpc   13.0-CURRENT powerpc           null   2019-12-31 01:21:28 /usr/obj/DESTDIRs/clang-powerpc-installworld-poud
FBSDpowerpc64 13.0-CURRENT powerpc.powerpc64 null   2020-01-01 15:22:36 /usr/obj/DESTDIRs/clang-powerpc64-installworld-poud

FBSDpowerpc was in use on/under:

# uname -apKU
FreeBSD FBSDG5L2 13.0-CURRENT FreeBSD 13.0-CURRENT #7 r363123M: Sun Jul 12 03:06:20 PDT 2020     markmi@FBSDFHUGE:/usr/obj/powerpc64vtsc_clang/powerpc.powerpc64/usr/src/powerpc.powerpc64/sys/GENERIC64vtsc-NODBG  powerpc powerpc64 1300101 1300101

# svnlite info /usr/ports
Path: /usr/ports
Working Copy Root Path: /usr/ports
URL: svn://svn.freebsd.org/ports/head
Relative URL: ^/head
Repository Root: svn://svn.freebsd.org/ports
Repository UUID: 35697150-7ecd-e111-bb59-0022644237b5
Revision: 542111
Node Kind: directory
Schedule: normal
Last Changed Author: vanilla
Last Changed Rev: 542111
Last Changed Date: 2020-07-12 21:32:18 -0700 (Sun, 12 Jul 2020)


===
Mark Millard
marklmi at yahoo.com
( dsl-only.net went
away in early 2018-Mar)

_______________________________________________
[email protected] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-ppc
To unsubscribe, send any mail to "[email protected]"
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.