在我的Xcode项目</libxml2>中找不到<libxml2 tree.h =“”>

时间:2012-05-14 05:32:30

标签: ios ipad

您好,在我的Xcode项目中,我包含了libxml2.dylib框架。我仍然收到错误:

  

未找到libxml2 / tree.h。

如何解决此问题?

我没有给出任何搜索标题路径。我正在使用Xcode 4.2

4 个答案:

答案 0 :(得分:4)

在我自己的使用libxml2的项目中,我修改了Header Search路径,以明确告诉编译器在哪里找到头文件:

pointer to where the libxml2 header files are

从“$(SDKROOT)”位可以看出,它实际上内置于随Xcode一起安装的SDK中。

答案 1 :(得分:2)

将标题搜索路径更改为:

  

/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.1.sdk/usr/include/libxml2

欢迎你:)

答案 2 :(得分:0)

阅读这些文件.........我认为这个网址对你有帮助....

在此网址Setting up your project file

中查看此主题

如果您不知道Xcode中的标题搜索路径,请按照步骤

go to target->click on BUild Setting-> search heder in search bar -> then you see search Path -> and check header search path

你进入Build Phase“Link with binary Libarys”并添加libxml2框架工作

 You follow all step after use step then click all tab (not combined tab) 

答案 3 :(得分:0)

我有类似的问题并按照本文的步骤修复问题:

http://www.optimusmobility.com/2013/06/11/how-to-resolve-libxmltree-h-file-not-found-error/