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

itkTestDriver link error with afl-clang-fast++ compiler #4649

Open
seanm opened this issue May 7, 2024 · 1 comment
Open

itkTestDriver link error with afl-clang-fast++ compiler #4649

seanm opened this issue May 7, 2024 · 1 comment
Labels
type:Compiler Compiler support or related warnings

Comments

@seanm
Copy link
Contributor

seanm commented May 7, 2024

I'm trying to build ITK master with the afl-clang-fast++ compiler and hit a link error right at the very end:

ld: Undefined symbols:
  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 libITKCommon.a[98](itkPoolMultiThreader.cxx.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 libITKCommon.a[98](itkPoolMultiThreader.cxx.o)
clang++: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [bin/itkTestDriver] Error 1
make[1]: *** [Modules/Core/TestKernel/src/CMakeFiles/itkTestDriver.dir/all] Error 2
make: *** [all] Error 2

Searching the codebase for itkTestDriver, I found a build setting named DO_NOT_BUILD_ITK_TEST_DRIVER, which if I set to 1 results in that thing not being built and therefore no link error. (Looks like I'm not the first to not want it, but interestingly that string appears exactly once.)

I'm configuring with:

BUILD_TESTING = OFF
DISABLE_MODULE_TESTS = ON

Which I thought disabled all testing stuff. Assuming so, why is itkTestDriver even being built? From its name, it seems like it should not be needed given my build options.

@seanm seanm added the type:Compiler Compiler support or related warnings label May 7, 2024
@thewtex
Copy link
Member

thewtex commented May 13, 2024

itkTestDriver is an executable that is installed. Other projects that depend on ITK may use it for their testing even though they may not want to test ITK themselves.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:Compiler Compiler support or related warnings
Projects
None yet
Development

No branches or pull requests

2 participants