VLCKit与iOS项目中的.mm文件冲突

Han*_*gbo 2 c++ xcode vlc libvlc ios

我正在iOS项目中使用VLCKit(MobileVLCKit.framework).起初一切都很好.然后我添加一些C++代码,所以一些文件是.mm文件.当我编译时,它失败了.Xcode日志

Undefined symbols for architecture armv7:
  "std::runtime_error::runtime_error(std::string const&)", referenced from:
      libebml::CRTError::CRTError(std::string const&, int) in MobileVLCKit(StdIOCallback.o)
  "std::ostream& std::ostream::_M_insert<void const*>(void const*)", referenced from:
      libebml::IOCallback::writeFully(void const*, unsigned long) in MobileVLCKit(IOCallback.o)
      libebml::IOCallback::readFully(void*, unsigned long) in MobileVLCKit(IOCallback.o)
  "std::runtime_error::runtime_error(std::string const&)", referenced from:
      libebml::IOCallback::writeFully(void const*, unsigned long) in MobileVLCKit(IOCallback.o)
      libebml::IOCallback::readFully(void*, unsigned long) in MobileVLCKit(IOCallback.o)
      "VTT for std::basic_stringstream<char, std::char_traits<char>, std::allocator<char> >", referenced from:
...
Run Code Online (Sandbox Code Playgroud)

我不知道为什么以及如何解决这个问题.

Han*_*gbo 5

我找到了解决方案:在Build Settings中将C++标准库更改为libstdc ++(GNU c ++标准库).