id,summary,reporter,owner,description,type,status,milestone,component,version,severity,resolution,keywords,cc 7512,Boost.Test segmentation fault when built with clang on Mac OS X.,manphiz@…,Gennadiy Rozental,"Mac OS X 10.8.2, Xcode 4.5.1 $ clang -v Apple clang version 4.1 (tags/Apple/clang-421.11.65) (based on LLVM 3.1svn) Target: x86_64-apple-darwin12.2.0 Thread model: posix Boost is built with clang without -std=c++11. The problem is shown below: {{{ $ cat boost_test_segfault.cc #define BOOST_TEST_MODULE test #include BOOST_AUTO_TEST_CASE( test1 ) { BOOST_CHECK(true); } $ clang++ -g -Wall -I/opt/homebrew/include boost_test_segfault.cc -L/opt/homebrew/lib -lboost_unit_test_framework-mt In file included from boost_test_segfault.cc:3: In file included from /opt/homebrew/include/boost/test/included/unit_test.hpp:20: In file included from /opt/homebrew/include/boost/test/impl/framework.ipp:29: In file included from /opt/homebrew/include/boost/test/test_tools.hpp:21: /opt/homebrew/include/boost/test/floating_point_comparison.hpp:251:25: warning: unused variable 'check_is_close' [-Wunused-variable] check_is_close_t const& check_is_close = unit_test::ut_detail::static_constant::value; ^ /opt/homebrew/include/boost/test/floating_point_comparison.hpp:273:25: warning: unused variable 'check_is_small' [-Wunused-variable] check_is_small_t const& check_is_small = unit_test::ut_detail::static_constant::value; ^ 2 warnings generated. $ ./a.out Running 1 test case... Segmentation fault: 11 }}} A detailed gdb session with ""bt full"" is attached. Also, on a relevant post on stackoverflow (http://stackoverflow.com/questions/12695625/boost-test-crashes-on-exit-with-clang-4-1-llvm-3-1svn) the user tried with building boost using clang with -std=c++11 -stdlib=libc++ and compile the test code with the same flag and the executable doesn't crash anymore. But I haven't tested that. I also tried to build the test program with llvm g++, but it runs with the same error. ",Bugs,closed,To Be Determined,test,Boost 1.51.0,Problem,invalid,,