2013-10-28 42 views
1

我剛將Mac操作系統更新到Maverick,它似乎破了東西!Boost python和Mac Mavericks

我正在編寫C++代碼並使用boost.python編寫python前端。升級前我有工作代碼,升級後我開始得到一個奇怪的鏈接錯誤:

darwin.link.dll /Users/Andy/software/boost-1.54.0/bin.v2/libs/python/build/darwin-4.8.1/debug/libboost_python.dylib 
Undefined symbols for architecture x86_64: 
    "std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::size() const", referenced from: 
     boost::python::converter::(anonymous namespace)::wstring_rvalue_from_python::extract(_object*) in builtin_converters.o 
    "std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >::empty() const", referenced from: 
    boost::python::converter::(anonymous namespace)::wstring_rvalue_from_python::extract(_object*) in builtin_converters.o 
    "std::basic_string<char, std::char_traits<char>, std::allocator<char> >::data() const", referenced from: 
    boost::python::converter::arg_to_python<std::basic_string<char, std::char_traits<char>, std::allocator<char> > >::arg_to_python(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) in numeric.o 

....頁面和頁面的類似錯誤。有誰知道發生了什麼?

+0

這可能是值得指出的是,我得到同樣的鏈接錯誤,當我嘗試重新安裝提振。 –

回答

0

在切換到小狗之前使用Xcode 5的地方?

您可以嘗試將項目使用的標準庫的版本更改爲Xcode的LLVM編譯器從C++ 98切換到C++ 11時的默認版本。

要檢查它走在Xcode中的目標設置,「生成設置」選項卡,在「蘋果LLVM 5.0 - 語言 - C++」的變化:

  • C++語言方言從「編譯器默認」爲「GNU ++ 98"
  • C++標準庫從‘編譯器默認’爲‘的libstdC++(GNU C++標準庫)’
相關問題