Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

2.24.2 fails at linking on macOS 13 (only there): Undefined symbols for architecture x86_64: "std::exception_ptr::__from_native_exception_pointer(void*) #5164

Closed
barracuda156 opened this issue Jul 6, 2024 · 11 comments

Comments

@barracuda156
Copy link
Contributor

CMakeFiles/TILEDB_CORE_OBJECTS.dir/__/external/blosc/src/shuffle.c.o "CMakeFiles/TILEDB_CORE_OBJECTS.dir/__/external/blosc/src/shuffle-generic.c.o" "CMakeFiles/TILEDB_CORE_OBJECTS.dir/__/external/blosc/src/bitshuffle-stub.c.o" "CMakeFiles/TILEDB_CORE_OBJECTS.dir/__/external/blosc/src/shuffle-avx2.c.o" common/CMakeFiles/baseline.dir/logger.cc.o common/CMakeFiles/baseline.dir/dynamic_memory/dynamic_memory.cc.o common/CMakeFiles/baseline.dir/exception/exception.cc.o common/CMakeFiles/baseline.dir/exception/status.cc.o common/CMakeFiles/baseline.dir/governor/governor.cc.o common/CMakeFiles/baseline.dir/heap_profiler.cc.o common/CMakeFiles/baseline.dir/heap_memory.cc.o common/CMakeFiles/baseline.dir/memory_tracker.cc.o common/CMakeFiles/baseline.dir/pmr.cc.o common/CMakeFiles/baseline.dir/polymorphic_allocator/polymorphic_allocator.cc.o  -Wl,-rpath,/opt/local/lib /opt/local/lib/libbz2.dylib /opt/local/lib/liblz4.dylib /opt/local/lib/libspdlog.1.14.1.dylib /opt/local/lib/libz.dylib /opt/local/lib/libzstd.a /opt/local/lib/libmagic.dylib /opt/local/libexec/openssl3/lib/libssl.dylib /opt/local/libexec/openssl3/lib/libcrypto.dylib -ldl /opt/local/lib/libfmt10/libfmt.10.2.1.dylib /opt/local/lib/libspdlog.1.14.1.dylib /opt/local/lib/libfmt10/libfmt.10.2.1.dylib
  Undefined symbols for architecture x86_64:
    "std::exception_ptr::__from_native_exception_pointer(void*)", referenced from:
        std::exception_ptr std::make_exception_ptr[abi:ne180100]<std::__1::future_error>(std::__1::future_error) in array.cc.o
        std::exception_ptr std::make_exception_ptr[abi:ne180100]<std::__1::future_error>(std::__1::future_error) in array_directory.cc.o
        std::exception_ptr std::make_exception_ptr[abi:ne180100]<std::__1::future_error>(std::__1::future_error) in fragment_consolidator.cc.o
        std::exception_ptr std::make_exception_ptr[abi:ne180100]<std::__1::future_error>(std::__1::future_error) in fragment_meta_consolidator.cc.o
        std::exception_ptr std::make_exception_ptr[abi:ne180100]<std::__1::future_error>(std::__1::future_error) in vfs.cc.o
        std::exception_ptr std::make_exception_ptr[abi:ne180100]<std::__1::future_error>(std::__1::future_error) in filter_pipeline.cc.o
        std::exception_ptr std::make_exception_ptr[abi:ne180100]<std::__1::future_error>(std::__1::future_error) in fragment_info.cc.o
        ...
    "___cxa_init_primary_exception", referenced from:
        std::exception_ptr std::make_exception_ptr[abi:ne180100]<std::__1::future_error>(std::__1::future_error) in array.cc.o
        std::exception_ptr std::make_exception_ptr[abi:ne180100]<std::__1::future_error>(std::__1::future_error) in array_directory.cc.o
        std::exception_ptr std::make_exception_ptr[abi:ne180100]<std::__1::future_error>(std::__1::future_error) in fragment_consolidator.cc.o
        std::exception_ptr std::make_exception_ptr[abi:ne180100]<std::__1::future_error>(std::__1::future_error) in fragment_meta_consolidator.cc.o
        std::exception_ptr std::make_exception_ptr[abi:ne180100]<std::__1::future_error>(std::__1::future_error) in vfs.cc.o
        std::exception_ptr std::make_exception_ptr[abi:ne180100]<std::__1::future_error>(std::__1::future_error) in filter_pipeline.cc.o
        std::exception_ptr std::make_exception_ptr[abi:ne180100]<std::__1::future_error>(std::__1::future_error) in fragment_info.cc.o
        ...
  ld: symbol(s) not found for architecture x86_64
  clang++: error: linker command failed with exit code 1 (use -v to see invocation)
  make[2]: *** [tiledb/libtiledb.dylib] Error 1

The full log from CI: https://github.com/macports/macports-ports/actions/runs/9818056679/job/27110136049?pr=24816

P. S. Notice that the build succeeds on macOS 12 and macOS 14 (on CI), as well as on my old macOS 10.6 (locally). The failure seems specific to macOS 13.

@barracuda156
Copy link
Contributor Author

@KiterLuc Do you know if this has been addressed already or not?

@KiterLuc
Copy link
Contributor

KiterLuc commented Jul 8, 2024

@barracuda156 I'm working with the team to see if we can reproduce.

@teo-tsirpanis

This comment was marked as resolved.

@barracuda156
Copy link
Contributor Author

@teo-tsirpanis Normally CI failures are reproducible locally. (In rare cases results may differ due to Xcode version or some local conflicts, if the build is not “clean”.) And yes, overlay repo is a convenient way to test locally a port which is not in the master.

Any update on the issue btw? I guess, macOS 13 is among officially supported systems, and we cannot update the port if CI do not pass.

@teo-tsirpanis
Copy link
Member

We do not know with certainty what caused the error. Some ideas that we tried (see action runs 11 to 13 in my MacPorts fork) did not manage to fix it.

We suspect that the failures are due to an external change in the compiler or libc++. We ran a local build of TileDB 2.20 which built successfully at the time of the Macports build, but it failed with the same error.

@barracuda156
Copy link
Contributor Author

barracuda156 commented Jul 14, 2024

I can try switching it to LLVM clang for now and see if that works.

UPD. Oh, it already uses LLVM clang on macOS 13 for some reason. But clang-18, while on macOS 12 it is clang-16. So I will try blacklisting clang-18, so that it falls back to an earlier one.

@KiterLuc
Copy link
Contributor

Thanks @barracuda156, let us know if that solves your issue or not.

@barracuda156
Copy link
Contributor Author

@KiterLuc Ah, yeah: it was actually using clang-18 before, and that failed. Falling back to clang-16 fixed the build. (I do not know the reason, this is just based on CI outcomes.)

@teo-tsirpanis
Copy link
Member

Closing, the source of the issue has been identified and it is not on TileDB.

@barracuda156
Copy link
Contributor Author

@teo-tsirpanis Just for the reference, could you please point to related issue?

@teo-tsirpanis
Copy link
Member

We have not opened an issue about it, but llvm/llvm-project#77653 looks related.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants