我正在尝试为ios中的opencore-amr项目编译一个静态库。我的设置是Xcode4.2 / iOS5 sdk(因为我还在运行Snow Leopard)。我已经调整了附加here的构建脚本以使用-isysroot而不是--sysroot,并将SDK var更新为/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.0.sdk
此时配置检查失败:
checking how to run the C preprocessor... /lib/cpp
configure: error: in `/Users/ldwong/Documents/xcode/opencore-amr-0.1.3':
configure: error: C preprocessor "/lib/cpp" fails sanity check
根据我的config.log,这次检查中的第一次失败是找到limits.h:
configure:7965: checking how to run the C preprocessor
configure:7996: gcc -arch armv6 -isysroot=/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.0.sdk -E conftest.c
In file included from conftest.c:12:
/Developer/Platforms/iPhoneOS.platform/Developer/usr/llvm-gcc-4.2/bin/../lib/gcc/arm-apple-darwin10/4.2.1/include/limits.h:15:25: error: no include path in which to search for limits.h
configure:7996: $? = 1
configure: failed program was:
...
更进一步,它也无法使用此命令找到assert.h:
configure:7996: gcc -arch armv6 -isysroot=/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.0.sdk -E -traditional-cpp conftest.c
conftest.c:14: error: assert.h: No such file or directory
有人能指出我错过了什么或做错了吗?谢谢!