Probleme mit boost :: program_options unter OSX mit LLVM verknüpfen

Aufgrund von Problemen mit Boost 1.49 habe ich Probleme, die Verbindungsphase in meinem C ++ - Programm zu durchlaufen. Ich habe zu C ++ gewechselt (-std=c++11 -libc=libc++), die gut für ein anderes Stück Code (die auch Boost verwendet). Boost wurde mit Homebrew installiert mit:

brew install boost --universal --with-mpi --with-icu

Das Problem beginnt mitboost::program_options. Ich erhalte die folgenden Linkfehler:

  "boost::program_options::validate(boost::any&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >*, int)", referenced from:

... etc. ...

ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

Dies ist ein wenig seltsam, da ein nm in der verwendeten Bibliothek zeigt, dass das Symbol vorhanden zu sein scheint:

nm -U /usr/local/lib/libboost_program_options-mt.dylib  | grep validate
0000000000019880 - 01 0000   FUN __ZN5boost15program_options8validateERNS_3anyERKSt6vectorISbIwSt11char_traitsIwESaIwEESaIS7_EEPSsi
0000000000019880 T __ZN5boost15program_options8validateERNS_3anyERKSt6vectorISbIwSt11char_traitsIwESaIwEESaIS7_EEPSsi
00000000000199e0 - 01 0000   FUN __ZN5boost15program_options8validateERNS_3anyERKSt6vectorISbIwSt11char_traitsIwESaIwEESaIS7_EEPbi
00000000000199e0 T __ZN5boost15program_options8validateERNS_3anyERKSt6vectorISbIwSt11char_traitsIwESaIwEESaIS7_EEPbi
0000000000019930 T __ZN5boost15program_options8validateERNS_3anyERKSt6vectorISsSaISsEEPSsi
0000000000019930 - 01 0000   FUN __ZN5boost15program_options8validateERNS_3anyERKSt6vectorISsSaISsEEPSsi
0000000000019c70 - 01 0000   FUN __ZN5boost15program_options8validateERNS_3anyERKSt6vectorISsSaISsEEPbi
0000000000019c70 T __ZN5boost15program_options8validateERNS_3anyERKSt6vectorISsSaISsEEPbi

Ich habe bereits versucht, Homebrew zu überreden, Boost mit Clang anstelle von gcc zu kompilieren, indem CXX und CXX_FLAGS vor der Installation entsprechend eingestellt wurden. Ich bin mir nicht sicher, ob es mir gelungen ist.

Zeiger sehr geschätzt.

Antworten auf die Frage(2)

Ihre Antwort auf die Frage