我可能遗漏了一些简单的东西,但在尝试构建时遇到以下链接器错误:
Undefined symbols for architecture i386:
"CAStreamBasicDescription::CAStreamBasicDescription()", referenced from:
-[AudioController initializeAUGraph] in AudioController.o
-[AudioController .cxx_construct] in AudioController.o
"CAStreamBasicDescription::AsString(char*, unsigned long) const", referenced from:
CAStreamBasicDescription::PrintFormat(__sFILE*, char const*, char const*) const in AudioController.o
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)
由于编译器正在查找CAStreamBasicDescription.h,我无法弄清楚这里发生了什么。我遇到过在遇到这种类型的错误时清除框架搜索路径的建议,但在那条路径中没有任何内容。可能是简单的事情,但我觉得我正在用消防水带喝水。谢谢!
答案 0 :(得分:3)
您是否也在项目中添加了CAStreamBasicDescription.cpp
?它是非官方Core Audio SDK的一部分,因此除非您自己编译,否则它不可用。