#65934 closed defect (fixed)
mesa @22.1.7 +tests requires added link library to libunwind on PPC Leopard, Mac OS X 10.5.8
Reported by: | ballapete (Peter "Pete" Dyballa) | Owned by: | |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.7.2 |
Keywords: | leopard ppc | Cc: | jeremyhu@… |
Port: | mesa |
Description
[111/1176] /opt/local/bin/g++-mp-7 -o src/util/util_tests src/util/util_tests.p/tests_bitset_test.cpp.o src/util/util_tests.p/tests_blob_test.cpp.o src/util/util_tests.p/tests_dag_test.cpp.o src/util/util_tests.p/tests_fast_idiv_by_const_test.cpp.o src/util/util_tests.p/tests_fast_urem_by_const_test.cpp.o src/util/util_tests.p/tests_int_min_max.cpp.o src/util/util_tests.p/tests_rb_tree_test.cpp.o src/util/util_tests.p/tests_register_allocate_test.cpp.o src/util/util_tests.p/tests_roundeven_test.cpp.o src/util/util_tests.p/tests_set_test.cpp.o src/util/util_tests.p/tests_sparse_array_test.cpp.o src/util/util_tests.p/tests_u_atomic_test.cpp.o src/util/util_tests.p/tests_u_debug_stack_test.cpp.o src/util/util_tests.p/tests_u_printf_test.cpp.o src/util/util_tests.p/tests_u_qsort_test.cpp.o src/util/util_tests.p/tests_vector_test.cpp.o src/util/util_tests.p/tests_string_buffer_test.cpp.o src/util/util_tests.p/tests_timespec_test.cpp.o src/util/util_tests.p/tests_mesa-sha1_test.cpp.o src/util/util_tests.p/tests_cache_test.cpp.o -L/opt/local/lib -I/opt/local/include -I/opt/local/include/LegacySupport -Wl,-dead_strip_dylibs -Wl,-headerpad_max_install_names -Wl,-undefined,error -Wl,-headerpad_max_install_names -latomic -lMacportsLegacySupport -arch ppc -pipe -Os -D_GLIBCXX_USE_CXX11_ABI=0 -arch ppc src/util/libmesa_util.a src/util/format/libmesa_format.a src/gtest/libgtest.a /opt/local/lib/libz.dylib -lm /opt/local/lib/libzstd.dylib -lSystem FAILED: src/util/util_tests /opt/local/bin/g++-mp-7 -o src/util/util_tests src/util/util_tests.p/tests_bitset_test.cpp.o src/util/util_tests.p/tests_blob_test.cpp.o src/util/util_tests.p/tests_dag_test.cpp.o src/util/util_tests.p/tests_fast_idiv_by_const_test.cpp.o src/util/util_tests.p/tests_fast_urem_by_const_test.cpp.o src/util/util_tests.p/tests_int_min_max.cpp.o src/util/util_tests.p/tests_rb_tree_test.cpp.o src/util/util_tests.p/tests_register_allocate_test.cpp.o src/util/util_tests.p/tests_roundeven_test.cpp.o src/util/util_tests.p/tests_set_test.cpp.o src/util/util_tests.p/tests_sparse_array_test.cpp.o src/util/util_tests.p/tests_u_atomic_test.cpp.o src/util/util_tests.p/tests_u_debug_stack_test.cpp.o src/util/util_tests.p/tests_u_printf_test.cpp.o src/util/util_tests.p/tests_u_qsort_test.cpp.o src/util/util_tests.p/tests_vector_test.cpp.o src/util/util_tests.p/tests_string_buffer_test.cpp.o src/util/util_tests.p/tests_timespec_test.cpp.o src/util/util_tests.p/tests_mesa-sha1_test.cpp.o src/util/util_tests.p/tests_cache_test.cpp.o -L/opt/local/lib -I/opt/local/include -I/opt/local/include/LegacySupport -Wl,-dead_strip_dylibs -Wl,-headerpad_max_install_names -Wl,-undefined,error -Wl,-headerpad_max_install_names -latomic -lMacportsLegacySupport -arch ppc -pipe -Os -D_GLIBCXX_USE_CXX11_ABI=0 -arch ppc src/util/libmesa_util.a src/util/format/libmesa_format.a src/gtest/libgtest.a /opt/local/lib/libz.dylib -lm /opt/local/lib/libzstd.dylib -lSystem Undefined symbols for architecture ppc: "_unw_getcontext", referenced from: _debug_backtrace_capture in libmesa_util.a(u_debug_stack.c.o) "_unw_init_local", referenced from: _debug_backtrace_capture in libmesa_util.a(u_debug_stack.c.o) "_unw_step", referenced from: _debug_backtrace_capture in libmesa_util.a(u_debug_stack.c.o) "_unw_get_reg", referenced from: _debug_backtrace_capture in libmesa_util.a(u_debug_stack.c.o) "_unw_get_proc_info", referenced from: _debug_backtrace_capture in libmesa_util.a(u_debug_stack.c.o) "_unw_get_proc_name", referenced from: _debug_backtrace_capture in libmesa_util.a(u_debug_stack.c.o) ld: symbol(s) not found for architecture ppc collect2: error: ld returned 1 exit status ninja: build stopped: subcommand failed. Command failed: cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_x11_mesa/mesa/work/build" && /opt/local/bin/ninja -j1 -v Exit code: 1 Error: Failed to build mesa: command execution failed
Attachments (1)
Change History (30)
Changed 2 years ago by ballapete (Peter "Pete" Dyballa)
comment:1 follow-ups: 2 4 10 Changed 2 years ago by kencu (Ken)
Peter, could you see if libunwind is installed on your system, try installing it if it is not installed, and then look in libunwind.dylib to see if those symbols are in there (using nm)?
If they are, try adding libunwind to your link flags
configure.ldflags-append -lunwind
and see if it links then.
comment:2 Changed 2 years ago by ballapete (Peter "Pete" Dyballa)
Replying to kencu:
Peter, could you see if libunwind is installed on your system
Not yet. I'll try to build and install.
comment:3 Changed 2 years ago by ballapete (Peter "Pete" Dyballa)
mesa
built. When I try to build the tests with meson
it reports:
time nice meson build-tests The Meson build system Version: 0.63.0 Source dir: /opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_x11_mesa/mesa/work/mesa-22.1.7 Build dir: /opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_x11_mesa/mesa/work/mesa-22.1.7/build-tests Build type: native build Program /opt/local/bin/python3.9 found: YES (/opt/local/bin/python3.9) Project name: mesa Project version: 22.1.7 C compiler for the host machine: cc (gcc 4.2.1 "powerpc-apple-darwin9-gcc-4.2.1 (GCC) 4.2.1 (Apple Inc. build 5577)") C linker for the host machine: cc ld64 85.2.1 C++ compiler for the host machine: c++ (gcc 7.5.0 "c++ (MacPorts gcc7 7.5.0_3) 7.5.0") C++ linker for the host machine: c++ ld64 127.2 Host machine cpu family: ppc Host machine cpu: power macintosh Checking if "-mtls-dialect=gnu2" runs: DID NOT COMPILE Program /opt/local/bin/python3.9 found: YES (/opt/local/bin/python3.9) meson.build:1018:2: ERROR: Problem encountered: When using GCC, version 4.4.6 or later is required.
Could be GCC 7
should be used as C compiler
too…
comment:4 Changed 2 years ago by ballapete (Peter "Pete" Dyballa)
Replying to kencu:
Peter, could you see if libunwind is installed on your system, try installing it if it is not installed
Big problem:
Error: Cannot install libgcc for the archs 'i386 ppc' because Error: its dependency libgcc7 cannot build for the required archs.
comment:5 follow-up: 8 Changed 2 years ago by kencu (Ken)
Don’t try to manually run the tests….it will almost always fail. Use the port test mechanism instead, which does many things to make it work right.
Try installing libunwind -universal.
comment:6 follow-up: 9 Changed 2 years ago by kencu (Ken)
by the way, Peter, on your system you have some kind of inconsistency.
cc
on your system points to /usr/bin/gcc-4.2
, but c++
is pointing to /opt/local/bin/g++-mp-7.0
.
MacPorts will override those when it is being used, but as you seem to use them yourself directly you might sort that out to be one or the other compiler.
comment:7 Changed 2 years ago by kencu (Ken)
Peter, looks like all your missing symbols are in libunwind.dylib as we thought:
$ nm -a libunwind.1.dylib | grep unw_ 000000000000354a t __ZN9libunwind12UnwindCursorINS_17LocalAddressSpaceENS_16Registers_x86_64EE7getInfoEP15unw_proc_info_t 0000000000003000 T __unw_add_dynamic_fde 0000000000003162 T __unw_remove_dynamic_fde 0000000000002e9d T _unw_get_fpreg 0000000000002f2d T _unw_get_proc_info 0000000000002f63 T _unw_get_proc_name 0000000000002e07 T _unw_get_reg 0000000000006615 T _unw_getcontext 0000000000002d5c T _unw_init_local 0000000000002f7b T _unw_is_fpreg 0000000000002f98 T _unw_is_signal_frame 0000000000002fa7 T _unw_iterate_dwarf_unwind_cache 0000000000008140 D _unw_local_addr_space 0000000000002f8a T _unw_regname 0000000000002f52 T _unw_resume 0000000000002edf T _unw_set_fpreg 0000000000002e47 T _unw_set_reg 0000000000002f22 T _unw_step
comment:8 Changed 2 years ago by ballapete (Peter "Pete" Dyballa)
comment:9 Changed 2 years ago by ballapete (Peter "Pete" Dyballa)
Replying to kencu:
by the way, Peter, on your system you have some kind of inconsistency.
cc
on your system points to/usr/bin/gcc-4.2
, butc++
is pointing to/opt/local/bin/g++-mp-7.0
.
I corrected this issue. The db line is also not OK (in port select --summary
). I am not sure whether I reset the gcc line…
comment:10 Changed 2 years ago by ballapete (Peter "Pete" Dyballa)
Replying to kencu:
[…] try adding libunwind to your link flags
configure.ldflags-append -lunwind
On the command line this does not seem to work. Besides, it's meson
that builds the port. I am awaiting now success or failure…
comment:12 Changed 2 years ago by ballapete (Peter "Pete" Dyballa)
The build process is over 300 steps further than where it crashed first, so the additional line to Portfile
is working (and should become part of it).
comment:13 Changed 2 years ago by ballapete (Peter "Pete" Dyballa)
The test variant
built, and most tests succeeded (maybe due to my use of Python 3.9
). During build and test phases a lot of complaints about the use of -mtls-dialect=gnu2
appear. Reading the help output of /opt/local/bin/gcc-mp-7
I can see:
Target: ppc-apple-darwin9 Configured with: /opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_lang_gcc7/gcc7/work/gcc-7.5.0/configure --prefix=/opt/local --build=ppc-apple-darwin9 --enable-languages=c,c++,objc,obj-c++,lto,fortran --libdir=/opt/local/lib/gcc7 --includedir=/opt/local/include/gcc7 --infodir=/opt/local/share/info --mandir=/opt/local/share/man --datarootdir=/opt/local/share/gcc-7 --with-local-prefix=/opt/local --with-system-zlib --disable-nls --program-suffix=-mp-7 --with-gxx-include-dir=/opt/local/include/gcc7/c++/ --with-gmp=/opt/local --with-mpfr=/opt/local --with-mpc=/opt/local --with-isl=/opt/local --enable-stage1-checking --disable-multilib --enable-lto --enable-libstdcxx-time --with-build-config=bootstrap-debug --with-as=/opt/local/bin/as --with-ld=/opt/local/bin/ld --with-ar=/opt/local/bin/ar --with-bugurl=https://trac.macports.org/newticket --disable-tls --with-pkgversion='MacPorts gcc7 7.5.0_3' Thread model: posix gcc version 7.5.0 (MacPorts gcc7 7.5.0_3) COLLECT_GCC_OPTIONS='-v' '--help' '-mmacosx-version-min=10.5.8' '-asm_macosx_version_min=10.5'
Should the option -disable-tls
be avoided in a new release of GCC 7
?
The mesa
file meson.build
contains this block:
513 # -mtls-dialect=gnu2 speeds up non-initial-exec TLS significantly but requires 514 # full toolchain (including libc) support. 515 have_mtls_dialect = false 516 foreach c_arg : get_option('c_args') 517 if c_arg.startswith('-mtls-dialect=') 518 have_mtls_dialect = true 519 break 520 endif 521 endforeach 522 if not have_mtls_dialect 523 # need .run to check libc support. meson aborts when calling .run when 524 # cross-compiling, but because this is just an optimization we can skip it 525 if meson.is_cross_build() and not meson.has_exe_wrapper() 526 warning('cannot auto-detect -mtls-dialect when cross-compiling, using compiler default') 527 else 528 # -fpic to force dynamic tls, otherwise TLS relaxation defeats check 529 gnu2_test = cc.run('int __thread x; int main() { return x; }', 530 args: ['-mtls-dialect=gnu2', '-fpic'], 531 name: '-mtls-dialect=gnu2') 532 if gnu2_test.returncode() == 0 and ( 533 # check for lld 13 bug: https://gitlab.freedesktop.org/mesa/mesa/-/issues/5665 534 host_machine.cpu_family() != 'x86_64' or 535 # get_linker_id misses LDFLAGS=-fuse-ld=lld: https://github.com/mesonbuild/meson/issues/6377 536 #cc.get_linker_id() != 'ld.lld' or 537 cc.links('''int __thread x; int y; int main() { __asm__( 538 "leaq x@TLSDESC(%rip), %rax\n" 539 "movq y@GOTPCREL(%rip), %rdx\n" 540 "call *x@TLSCALL(%rax)\n"); }''', name: 'split TLSDESC') 541 ) 542 c_args += '-mtls-dialect=gnu2' 543 cpp_args += '-mtls-dialect=gnu2' 544 endif 545 endif
Can it be that it erroneously returns that MacPorts gcc7 7.5.0_3
supports the -mtls-dialect=gnu2
option?
comment:14 Changed 2 years ago by kencu (Ken)
Summary: | mesa @22.1.7 +tests does not build on PPC Leopard, Mac OS X 10.5.8, because of Undefined symbols for architecture ppc → mesa @22.1.7 +tests requires added link library to libunwind on PPC Leopard, Mac OS X 10.5.8 |
---|
comment:15 Changed 2 years ago by kencu (Ken)
So I think the reason that the link to the libunwind library is needed here is that the libunwind-headers are installed, and the build is picking up those headers, which then reference certain symbols that exist in libunwind.dylib but not in the system gcc unwinder. If the libunwind-headers port was not installed, then the link to libunwind.dylib would likely not be needed. This is to be explicitly verified, but appears likely.
The reason we have libunwind at all is to allow certain Apple software like cctools, ld64, and probably llvm/clang/etc to find the unwinding symbols that are assumed to be there.
Iain points out that this is both fragile and highly likely to be broken; you have to have one unwinder in use.
So we may be in a situation where we build and install libunwind/libunwind-headers to allow other things to build, knowing that in so doing we are actually breaking unwinding.
comment:16 follow-up: 24 Changed 2 years ago by ballapete (Peter "Pete" Dyballa)
I added the CFLAG -H
to the GCC7 compiler flags
– and the result is this:
[81/1176] /opt/local/bin/gcc-mp-7 -Isrc/util/libmesa_util.a.p -Isrc/util -I../mesa-22.1.7/src/util -Iinclude -I../mesa-22.1.7/include -Isrc -I../mesa-22.1.7/src -Isrc/mapi -I../mesa-22.1.7/src/mapi -Isrc/mesa -I../mesa-22.1.7/src/mesa -I../mesa-22.1.7/src/gallium/include -Isrc/gallium/auxiliary -I../mesa-22.1.7/src/gallium/auxiliary -I/opt/local/include/LegacySupport -I/opt/local/include -fvisibility=hidden -fdiagnostics-color=always -Wall -Winvalid-pch -std=c11 -O2 -g -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS '-DPACKAGE_VERSION="22.1.7"' '-DPACKAGE_BUGREPORT="https://gitlab.freedesktop.org/mesa/mesa/-/issues"' -DHAVE_SWRAST -DBUILDING_MESA -DHAVE_X11_PLATFORM -DHAVE_XCB_PLATFORM -DUSE_ELF_TLS -DENABLE_ST_OMX_BELLAGIO=0 -DENABLE_ST_OMX_TIZONIA=0 -DGLX_INDIRECT_RENDERING -DGLX_DIRECT_RENDERING -DGLX_USE_APPLEGL -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_ATTRIBUTE_FORMAT -DHAVE_FUNC_ATTRIBUTE_PACKED -DHAVE_FUNC_ATTRIBUTE_RETURNS_NONNULL -DHAVE_FUNC_ATTRIBUTE_NORETURN -DHAVE_FUNC_ATTRIBUTE_VISIBILITY -DUSE_GCC_ATOMIC_BUILTINS -DMISSING_64BIT_ATOMICS -DHAS_SCHED_H -DHAVE_SYS_SYSCTL_H -DHAVE_XLOCALE_H -DHAVE_DLFCN_H -DHAVE_SYS_SHM_H -DHAVE_STRTOF -DHAVE_TIMESPEC_GET -DHAVE_FLOCK -DHAVE_STRTOK_R -DHAVE_QSORT_R -DHAVE_POSIX_MEMALIGN -DHAVE_DIRENT_D_TYPE -DHAVE_STRTOD_L -DHAVE_DLADDR -DHAVE_ZLIB -DHAVE_ZSTD -DHAVE_COMPRESSION -DHAVE_PTHREAD -DMESA_EXECMEM -DHAVE_LIBUNWIND -DVK_USE_PLATFORM_XCB_KHR -DVK_USE_PLATFORM_XLIB_KHR -DVK_USE_PLATFORM_MACOS_MVK -DVK_USE_PLATFORM_METAL_EXT -DVK_ENABLE_BETA_EXTENSIONS -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=return-type -Werror=empty-body -Werror=incompatible-pointer-types -Werror=int-conversion -Wimplicit-fallthrough -Wno-missing-field-initializers -Wno-format-truncation -fno-math-errno -fno-trapping-math -fno-common -Werror=format -Wformat-security -pipe -Os -H -arch ppc -Werror=pointer-arith -MD -MQ src/util/libmesa_util.a.p/u_debug_memory.c.o -MF src/util/libmesa_util.a.p/u_debug_memory.c.o.d -o src/util/libmesa_util.a.p/u_debug_memory.c.o -c ../mesa-22.1.7/src/util/u_debug_memory.c FAILED: src/util/libmesa_util.a.p/u_debug_memory.c.o /opt/local/bin/gcc-mp-7 -Isrc/util/libmesa_util.a.p -Isrc/util -I../mesa-22.1.7/src/util -Iinclude -I../mesa-22.1.7/include -Isrc -I../mesa-22.1.7/src -Isrc/mapi -I../mesa-22.1.7/src/mapi -Isrc/mesa -I../mesa-22.1.7/src/mesa -I../mesa-22.1.7/src/gallium/include -Isrc/gallium/auxiliary -I../mesa-22.1.7/src/gallium/auxiliary -I/opt/local/include/LegacySupport -I/opt/local/include -fvisibility=hidden -fdiagnostics-color=always -Wall -Winvalid-pch -std=c11 -O2 -g -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS '-DPACKAGE_VERSION="22.1.7"' '-DPACKAGE_BUGREPORT="https://gitlab.freedesktop.org/mesa/mesa/-/issues"' -DHAVE_SWRAST -DBUILDING_MESA -DHAVE_X11_PLATFORM -DHAVE_XCB_PLATFORM -DUSE_ELF_TLS -DENABLE_ST_OMX_BELLAGIO=0 -DENABLE_ST_OMX_TIZONIA=0 -DGLX_INDIRECT_RENDERING -DGLX_DIRECT_RENDERING -DGLX_USE_APPLEGL -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_ATTRIBUTE_FORMAT -DHAVE_FUNC_ATTRIBUTE_PACKED -DHAVE_FUNC_ATTRIBUTE_RETURNS_NONNULL -DHAVE_FUNC_ATTRIBUTE_NORETURN -DHAVE_FUNC_ATTRIBUTE_VISIBILITY -DUSE_GCC_ATOMIC_BUILTINS -DMISSING_64BIT_ATOMICS -DHAS_SCHED_H -DHAVE_SYS_SYSCTL_H -DHAVE_XLOCALE_H -DHAVE_DLFCN_H -DHAVE_SYS_SHM_H -DHAVE_STRTOF -DHAVE_TIMESPEC_GET -DHAVE_FLOCK -DHAVE_STRTOK_R -DHAVE_QSORT_R -DHAVE_POSIX_MEMALIGN -DHAVE_DIRENT_D_TYPE -DHAVE_STRTOD_L -DHAVE_DLADDR -DHAVE_ZLIB -DHAVE_ZSTD -DHAVE_COMPRESSION -DHAVE_PTHREAD -DMESA_EXECMEM -DHAVE_LIBUNWIND -DVK_USE_PLATFORM_XCB_KHR -DVK_USE_PLATFORM_XLIB_KHR -DVK_USE_PLATFORM_MACOS_MVK -DVK_USE_PLATFORM_METAL_EXT -DVK_ENABLE_BETA_EXTENSIONS -Werror=implicit-function-declaration -Werror=missing-prototypes -Werror=return-type -Werror=empty-body -Werror=incompatible-pointer-types -Werror=int-conversion -Wimplicit-fallthrough -Wno-missing-field-initializers -Wno-format-truncation -fno-math-errno -fno-trapping-math -fno-common -Werror=format -Wformat-security -pipe -Os -H -arch ppc -Werror=pointer-arith -MD -MQ src/util/libmesa_util.a.p/u_debug_memory.c.o -MF src/util/libmesa_util.a.p/u_debug_memory.c.o.d -o src/util/libmesa_util.a.p/u_debug_memory.c.o -c ../mesa-22.1.7/src/util/u_debug_memory.c . ../mesa-22.1.7/src/gallium/include/pipe/p_config.h .. /opt/local/lib/gcc7/gcc/ppc-apple-darwin9/7.5.0/include-fixed/limits.h ... /opt/local/lib/gcc7/gcc/ppc-apple-darwin9/7.5.0/include-fixed/syslimits.h .... /opt/local/lib/gcc7/gcc/ppc-apple-darwin9/7.5.0/include-fixed/limits.h ..... /usr/include/limits.h ...... /usr/include/sys/cdefs.h ...... /usr/include/machine/limits.h ....... /usr/include/ppc/limits.h ........ /usr/include/ppc/_limits.h ...... /usr/include/sys/syslimits.h .. ../mesa-22.1.7/src/util/u_endian.h ... /usr/include/machine/endian.h .... /usr/include/ppc/endian.h ..... /usr/include/sys/_endian.h .. ../mesa-22.1.7/src/util/detect_os.h . ../mesa-22.1.7/src/gallium/auxiliary/os/os_thread.h .. ../mesa-22.1.7/src/gallium/include/pipe/p_compiler.h ... ../mesa-22.1.7/include/c99_compat.h .... ../mesa-22.1.7/include/no_extern_c.h ... ../mesa-22.1.7/src/gallium/include/pipe/p_config.h ... ../mesa-22.1.7/src/util/macros.h .... /opt/local/include/LegacySupport/stdio.h ..... /opt/local/include/LegacySupport/MacportsLegacySupport.h ..... /usr/include/stdio.h ...... /usr/include/_types.h ....... /usr/include/sys/_types.h ........ /usr/include/machine/_types.h ......... /usr/include/ppc/_types.h .... /usr/include/assert.h .... ../mesa-22.1.7/include/c99_compat.h ..... ../mesa-22.1.7/include/no_extern_c.h .... ../mesa-22.1.7/include/c11_compat.h ..... ../mesa-22.1.7/include/no_extern_c.h .... /opt/local/lib/gcc7/gcc/ppc-apple-darwin9/7.5.0/include/stdint.h ..... /opt/local/lib/gcc7/gcc/ppc-apple-darwin9/7.5.0/include-fixed/stdint.h ... /opt/local/include/LegacySupport/stdlib.h .... /usr/include/stdlib.h ..... /usr/include/available.h ..... /usr/include/sys/wait.h ...... /usr/include/sys/signal.h ....... /usr/include/sys/appleapiopts.h ....... /usr/include/machine/signal.h ........ /usr/include/ppc/signal.h ......... /usr/include/ppc/_structs.h ....... /usr/include/sys/_structs.h ........ /usr/include/machine/_structs.h ......... /usr/include/ppc/_structs.h .......... /usr/include/mach/ppc/_structs.h ...... /usr/include/sys/resource.h ....... /usr/include/sys/_structs.h ..... /usr/include/alloca.h ..... /usr/include/machine/types.h ...... /usr/include/ppc/types.h ... /opt/local/include/LegacySupport/string.h .... /usr/include/string.h ... /opt/local/lib/gcc7/gcc/ppc-apple-darwin9/7.5.0/include/stddef.h ... /opt/local/lib/gcc7/gcc/ppc-apple-darwin9/7.5.0/include/stdarg.h ... /opt/local/lib/gcc7/gcc/ppc-apple-darwin9/7.5.0/include-fixed/limits.h ... /opt/local/lib/gcc7/gcc/ppc-apple-darwin9/7.5.0/include/stdbool.h .. ../mesa-22.1.7/src/util/u_debug.h ... /usr/include/sys/types.h .... /usr/include/sys/_structs.h ... /opt/local/include/LegacySupport/unistd.h .... /usr/include/unistd.h ..... /opt/local/include/LegacySupport/sys/unistd.h ...... /opt/local/include/LegacySupport/MacportsLegacySupport.h ...... /usr/include/sys/unistd.h ..... /usr/include/sys/select.h ...... /usr/include/sys/_structs.h ...... /usr/include/sys/_select.h ... ../mesa-22.1.7/src/util/os_misc.h .... ../mesa-22.1.7/src/util/detect_os.h .... /usr/include/signal.h .. ../mesa-22.1.7/src/util/u_thread.h ... /usr/include/errno.h .... /usr/include/sys/errno.h ... ../mesa-22.1.7/include/c11/threads.h .... /opt/local/include/LegacySupport/time.h ..... /usr/include/time.h ...... /usr/include/_structs.h ....... /usr/include/sys/_structs.h .... ../mesa-22.1.7/include/c99_compat.h ..... ../mesa-22.1.7/include/no_extern_c.h .... ../mesa-22.1.7/include/c11/threads_posix.h ..... /opt/local/lib/gcc7/gcc/ppc-apple-darwin9/7.5.0/include-fixed/limits.h ..... /usr/include/errno.h ..... /usr/include/sched.h ...... /opt/local/include/LegacySupport/pthread_impl.h ....... /usr/include/pthread_impl.h ..... /opt/local/include/LegacySupport/pthread.h ...... /usr/include/pthread.h ... ../mesa-22.1.7/src/util/macros.h . ../mesa-22.1.7/src/util/u_debug_stack.h In file included from ../mesa-22.1.7/src/util/u_debug_memory.c:42:0: ../mesa-22.1.7/src/util/u_debug_stack.h:35:10: fatal error: libunwind.h: No such file or directory #include <libunwind.h> ^~~~~~~~~~~~~ compilation terminated. ninja: build stopped: subcommand failed. Command failed: cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_x11_mesa/mesa/work/build" && /opt/local/bin/ninja -j1 -v Exit code: 1
libunwind and libunwind-headers
are deactivated
. I wanted to build the test variant
to see whether it builds with the deactivated ports
. And afterwards I wanted to see when which libunwind C header
would be included. The first case is found and I am going to clean and build again with activated libunwind ports
to see all candidates.
comment:17 follow-up: 20 Changed 2 years ago by ballapete (Peter "Pete" Dyballa)
On High Sierra
I saw that mesa requested LegacySupport
– is this necessary?
comment:18 Changed 2 years ago by kencu (Ken)
In the meson.build script, it is assumed that Darwin will have libunwind in System:
if host_machine.system() == 'darwin' dep_unwind = meson.get_compiler('c').find_library('System') else dep_unwind = dependency('libunwind', required : _libunwind == 'enabled') endif if dep_unwind.found() pre_args += '-DHAVE_LIBUNWIND' endif
so that is why we have to add the specific libunwind addition for systems that don't have libunwind inside libSystem. Let me try something else...
comment:19 follow-ups: 21 26 29 Changed 2 years ago by kencu (Ken)
disabling libunwind works on Leopard Intel:
configure.args-append -Dlibunwind=disabled
that is probably the simplest, cleanest thing to do...
comment:20 Changed 2 years ago by kencu (Ken)
Replying to ballapete:
On
High Sierra
I saw thatmesa requested LegacySupport
– is this necessary?
yes it is
comment:21 Changed 2 years ago by ballapete (Peter "Pete" Dyballa)
Replying to kencu:
disabling libunwind works on Leopard Intel:
configure.args-append -Dlibunwind=disabled
I'll try that later on PPC, right now the build to record the use of libunwind C header files
is running…
comment:22 follow-up: 23 Changed 2 years ago by kencu (Ken)
And the test run of mesa on Leopard Intel (using gcc7 due to that silly llrint math error with clang-7.0) does actually very well too... which is kind of a miracle.
Ok: 46 Expected Fail: 0 Fail: 1 Unexpected Pass: 0 Skipped: 0 Timeout: 1
the one fail is because we're using emulated_tls with GCC, so that is not really an error at all:
src/mapi/shared-glapi/libglapi.0.dylib: unknown symbol exported: __emutls_v._glapi_tls_Context src/mapi/shared-glapi/libglapi.0.dylib: unknown symbol exported: __emutls_v._glapi_tls_Dispatch
and the test that timed out I'm not sure of just now:
=================================== 48/48 ==================================== test: mesa:util / util_tests start time: 19:08:10 duration: 180.22s result: killed by signal 15 SIGTERM command: MALLOC_PERTURB_=28 /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_x11_mesa/mesa/work/build/src/util/util_tests ----------------------------------- stdout ----------------------------------- Running main() from ../mesa-22.1.7/src/gtest/src/gtest_main.cc [==========] Running 130 tests from 48 test suites. [----------] Global test environment set-up. [----------] 18 tests from bitset [ RUN ] bitset.sizes [ OK ] bitset.sizes (0 ms) [ RUN ] bitset.test_set_clear [ OK ] bitset.test_set_clear (0 ms) [ RUN ] bitset.test_set_ones [ OK ] bitset.test_set_ones (0 ms) [ RUN ] bitset.test_basic_range [ OK ] bitset.test_basic_range (0 ms) [ RUN ] bitset.test_bitset_ffs [ OK ] bitset.test_bitset_ffs (0 ms) [ RUN ] bitset.test_range_bits [ OK ] bitset.test_range_bits (0 ms) [ RUN ] bitset.test_and [ OK ] bitset.test_and (0 ms) [ RUN ] bitset.test_or [ OK ] bitset.test_or (0 ms) [ RUN ] bitset.test_not [ OK ] bitset.test_not (0 ms) [ RUN ] bitset.test_shr_zero [ OK ] bitset.test_shr_zero (0 ms) [ RUN ] bitset.test_shl_zero [ OK ] bitset.test_shl_zero (0 ms) [ RUN ] bitset.test_shr_walking_bit [ OK ] bitset.test_shr_walking_bit (0 ms) [ RUN ] bitset.test_shl_walking_bit [ OK ] bitset.test_shl_walking_bit (0 ms) [ RUN ] bitset.test_shr_multiple_words [ OK ] bitset.test_shr_multiple_words (0 ms) [ RUN ] bitset.test_shl_multiple_words [ OK ] bitset.test_shl_multiple_words (0 ms) [ RUN ] bitset.test_shr_two_words [ OK ] bitset.test_shr_two_words (0 ms) [ RUN ] bitset.test_shl_two_words [ OK ] bitset.test_shl_two_words (0 ms) [ RUN ] bitset.test_setrange_across_word_boundary [ OK ] bitset.test_setrange_across_word_boundary (0 ms) [----------] 18 tests from bitset (0 ms total) [----------] 4 tests from BlobTest [ RUN ] BlobTest.WriteAndReadFunctions [ OK ] BlobTest.WriteAndReadFunctions (0 ms) [ RUN ] BlobTest.Alignment [ OK ] BlobTest.Alignment (0 ms) [ RUN ] BlobTest.DetectOverrun [ OK ] BlobTest.DetectOverrun (0 ms) [ RUN ] BlobTest.BigObjects [ OK ] BlobTest.BigObjects (3 ms) [----------] 4 tests from BlobTest (3 ms total) [----------] 6 tests from dag_test [ RUN ] dag_test.simple [ OK ] dag_test.simple (0 ms) [ RUN ] dag_test.duplicate_edge [ OK ] dag_test.duplicate_edge (0 ms) [ RUN ] dag_test.duplicate_edge_max_data [ OK ] dag_test.duplicate_edge_max_data (0 ms) [ RUN ] dag_test.simple_many_children [ OK ] dag_test.simple_many_children (0 ms) [ RUN ] dag_test.simple_many_parents [ OK ] dag_test.simple_many_parents (0 ms) [ RUN ] dag_test.complex [ OK ] dag_test.complex (0 ms) [----------] 6 tests from dag_test (0 ms total) [----------] 21 tests from fast_idiv_by_const [ RUN ] fast_idiv_by_const.uint8_add_sat [ OK ] fast_idiv_by_const.uint8_add_sat (7 ms) [ RUN ] fast_idiv_by_const.uint8_mul_add [ OK ] fast_idiv_by_const.uint8_mul_add (4 ms) [ RUN ] fast_idiv_by_const.int8 [ OK ] fast_idiv_by_const.int8 (10 ms) [ RUN ] fast_idiv_by_const.uint16_add_sat_bounded [ OK ] fast_idiv_by_const.uint16_add_sat_bounded (37 ms) [ RUN ] fast_idiv_by_const.uint16_add_sat_full [ OK ] fast_idiv_by_const.uint16_add_sat_full (45 ms) [ RUN ] fast_idiv_by_const.uint16_mul_add_bounded [ OK ] fast_idiv_by_const.uint16_mul_add_bounded (34 ms) [ RUN ] fast_idiv_by_const.uint16_mul_add_full [ OK ] fast_idiv_by_const.uint16_mul_add_full (40 ms) [ RUN ] fast_idiv_by_const.int16 [ OK ] fast_idiv_by_const.int16 (59 ms) [ RUN ] fast_idiv_by_const.uint32_add_sat_bounded [ OK ] fast_idiv_by_const.uint32_add_sat_bounded (38 ms) [ RUN ] fast_idiv_by_const.uint32_add_sat_full [ OK ] fast_idiv_by_const.uint32_add_sat_full (56 ms) [ RUN ] fast_idiv_by_const.uint32_mul_add_bounded [ OK ] fast_idiv_by_const.uint32_mul_add_bounded (36 ms) [ RUN ] fast_idiv_by_const.uint32_mul_add_full [ OK ] fast_idiv_by_const.uint32_mul_add_full (53 ms) [ RUN ] fast_idiv_by_const.int32 [ OK ] fast_idiv_by_const.int32 (60 ms) [ RUN ] fast_idiv_by_const.util_fast_udiv32 [ OK ] fast_idiv_by_const.util_fast_udiv32 (51 ms) [ RUN ] fast_idiv_by_const.util_fast_udiv32_nuw [ OK ] fast_idiv_by_const.util_fast_udiv32_nuw (50 ms) [ RUN ] fast_idiv_by_const.util_fast_udiv32_u31_d_not_one [ OK ] fast_idiv_by_const.util_fast_udiv32_u31_d_not_one (47 ms) [ RUN ] fast_idiv_by_const.uint64_add_sat_bounded [ OK ] fast_idiv_by_const.uint64_add_sat_bounded (53 ms) [ RUN ] fast_idiv_by_const.uint64_add_sat_full [ OK ] fast_idiv_by_const.uint64_add_sat_full (88 ms) [ RUN ] fast_idiv_by_const.uint64_mul_add_bounded [ OK ] fast_idiv_by_const.uint64_mul_add_bounded (52 ms) [ RUN ] fast_idiv_by_const.uint64_mul_add_full [ OK ] fast_idiv_by_const.uint64_mul_add_full (85 ms) [ RUN ] fast_idiv_by_const.int64 [ OK ] fast_idiv_by_const.int64 (80 ms) [----------] 21 tests from fast_idiv_by_const (986 ms total) [----------] 2 tests from fast_urem_by_const [ RUN ] fast_urem_by_const.random [ OK ] fast_urem_by_const.random (16 ms) [ RUN ] fast_urem_by_const.special_cases [ OK ] fast_urem_by_const.special_cases (0 ms) [----------] 2 tests from fast_urem_by_const (16 ms total) [----------] 3 tests from int_min_max [ RUN ] int_min_max.u_intN_min [ OK ] int_min_max.u_intN_min (0 ms) [ RUN ] int_min_max.u_intN_max [ OK ] int_min_max.u_intN_max (0 ms) [ RUN ] int_min_max.u_uintN_max [ OK ] int_min_max.u_uintN_max (0 ms) [----------] 3 tests from int_min_max (0 ms total) [----------] 1 test from RBTreeTest [ RUN ] RBTreeTest.InsertAndSearch [ OK ] RBTreeTest.InsertAndSearch (2 ms) [----------] 1 test from RBTreeTest (2 ms total) [----------] 5 tests from ra_test [ RUN ] ra_test.thumb [ OK ] ra_test.thumb (0 ms) [ RUN ] ra_test.thumb_contigregs [ OK ] ra_test.thumb_contigregs (0 ms) [ RUN ] ra_test.nonintersect_contigregs [ OK ] ra_test.nonintersect_contigregs (0 ms) [ RUN ] ra_test.aligned_contigregs [ OK ] ra_test.aligned_contigregs (0 ms) [ RUN ] ra_test.serialization_roundtrip [ OK ] ra_test.serialization_roundtrip (0 ms) [----------] 5 tests from ra_test (0 ms total) [----------] 2 tests from Rounding [ RUN ] Rounding.RoundevenFloat [ OK ] Rounding.RoundevenFloat (0 ms) [ RUN ] Rounding.RoundevenDouble [ OK ] Rounding.RoundevenDouble (0 ms) [----------] 2 tests from Rounding (0 ms total) [----------] 4 tests from set [ RUN ] set.basic [ OK ] set.basic (0 ms) [ RUN ] set.clone [ OK ] set.clone (0 ms) [ RUN ] set.remove_key [ OK ] set.remove_key (0 ms) [ RUN ] set.search_or_add [ OK ] set.search_or_add (0 ms) [----------] 4 tests from set (0 ms total) [----------] 1 test from SparseArrayTest [ RUN ] SparseArrayTest.Multithread ============================================================================== Summary of Failures: 20/48 mesa:mapi / shared-glapi symbols check FAIL 0.16s exit status 1 48/48 mesa:util / util_tests TIMEOUT 180.22s killed by signal 15 SIGTERM
OK, I'll push that fix.
comment:23 Changed 2 years ago by ballapete (Peter "Pete" Dyballa)
Replying to kencu:
And the test run of mesa on Leopard Intel (using gcc7 due to that silly llrint math error with clang-7.0) does actually very well too... which is kind of a miracle.
With Python 3.9
they just fail…
comment:24 Changed 2 years ago by ballapete (Peter "Pete" Dyballa)
Replying to ballapete:
I added the
CFLAG -H
to theGCC7 compiler flags
– and the result is this:
And the second result is this:
[86/1176] /opt/local/bin/gcc-mp-7 … -c ../mesa-22.1.7/src/util/u_debug_stack.c
comment:25 Changed 2 years ago by kencu (Ken)
Resolution: | → fixed |
---|---|
Status: | new → closed |
comment:26 follow-up: 27 Changed 2 years ago by ballapete (Peter "Pete" Dyballa)
Replying to kencu:
disabling libunwind works on Leopard Intel:
configure.args-append -Dlibunwind=disabled
It started to work here too: -DHAVE_LIBUNWIND
is not passed to the compiler.
comment:27 follow-up: 28 Changed 2 years ago by kencu (Ken)
Replying to ballapete:
It started to work here too:
-DHAVE_LIBUNWIND
is not passed to the compiler.
Just like magic :>
comment:28 Changed 2 years ago by ballapete (Peter "Pete" Dyballa)
comment:29 Changed 2 years ago by ballapete (Peter "Pete" Dyballa)
Replying to kencu:
disabling libunwind works on Leopard Intel:
configure.args-append -Dlibunwind=disabled
This works on Leopard PPC as well.
Main.log from PPC Leopard