iphone – 在xcode 4.x中添加静态库的Header搜索路径中的混淆?

前端之家收集整理的这篇文章主要介绍了iphone – 在xcode 4.x中添加静态库的Header搜索路径中的混淆?前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。
我在 xcode 4.5中添加核心图静态库时感到困惑.它与xcode 3.x版本不同.我尝试了很多东西,它没有找到头文件链接错误.

我按照以下步骤操作.在哪种情况下,我们必须在Header搜索路径中使用递归.如果有错误,请帮忙吗?

1)Adding coreplot library and its headers in Xcode project.(ticked
for copy locally)

2)converted compiler to LLVM GCC 4.2 in project build settings.(not in
target build setting)

3)Compiler for thumb will be “NO”

4)Added Header Search Path in project build settings as,with
recursive
“$(SRCROOT)/Libs/CorePlot/CorePlotHeaders”

5)Added Header Search Path in target build settings as
$(inherited)

6)Library search path will be as empty in both target and project
build settings.

7)-ObjC was added in Other linker flag in target build
settings.Removed -all_load from it.

8)Always search path will be YES in both target and project build
settings.

9)Build archive architecture only will be YES.

解决方法

我在几天前试图以这种方式添加CorePlot时遇到了同样的问题,但我发现有一个更简单的过程:

  1. Copy the CorePlotHeaders directory to your Xcode project

  2. Copy the Core Plot library to your Xcode project.

  3. Open your apps Target Build Settings,and for Other Linker Flags include this:

-ObjC (-all_load used to be required as a linker flag,but this is no longer needed in Xcode 4.2)

  1. Add the QuartzCore framework to the project.

  2. Change your C/C++ Compiler in the project build settings to LLVM GCC 4.2 or LLVM 1.6.

就我而言,我不需要更改我的C/C++编译器来使CorePlot正常工作

猜你在找的Xcode相关文章