
On 2009-11-10 23:48:49 +1100, Roman Perepelitsa
As far as I remember, boost_unit_test_framework defines main function. Having two main functions in the same application might be what's causing your problems. Another possibility is that the library and the program are compiled with different standard libraries.
Good thoughts, but: 1. Boost Test does not define main unless you tell it to, and that's only in a header. The library itself doesn't contain main: % nm /opt/local/lib/libboost_unit_test_framework-mt-d.dylib |c++filt|grep main 00000000000759e6 T boost::runtime::cla::argv_traverser::remainder(int&, char**) 000000000002e26a T boost::unit_test::unit_test_main(bool (*)(), int, char**) 0000000000136670 S typeinfo for std::domain_error 00000000000b2a0a S typeinfo name for std::domain_error % 2. I compiled the library myself, or at least MacPorts did, using the same standard library. I'm pretty sure it's caused by the unit test library doing something dodgy at static initialisation time. Though I don't know exactly what... Mainly I'm interested in whether anyone else can replicate this problem.