加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 百科 > 正文

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

发布时间:2020-12-14 17:32:03 所属栏目:百科 来源:网络整理
导读:我在 xcode 4.5中添加核心图静态库时感到困惑.它与xcode 3.x版本不同.我尝试了很多东西,它没有找到头文件和链接器错误. 我按照以下步骤操作.在哪种情况下,我们必须在Header搜索路径中使用递归.如果有错误,请帮忙吗? 1)Adding coreplot library and its head
我在 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正常工作

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读