libxml/tree.h 没有这样的文件或目录 [英] libxml/tree.h no such file or directory

查看:39
本文介绍了libxml/tree.h 没有这样的文件或目录的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我收到以下错误.

libxml/tree.h 没有那个文件或目录

libxml/tree.h no such file or directory

我已经将 libxml2.dylib 添加到我的项目中,但是我遇到了此类问题.请帮帮我.

I have already added libxml2.dylib to my project, however I am getting this type of trouble. Please help me.

推荐答案

按照指示操​​作 此处,在设置您的项目文件"下.

Follow the directions here, under "Setting up your project file."

你需要将 libxml2.dylib 添加到你的项目中(不要把它放在框架部分).在 Mac 上,你会在 /usr/lib/libxml2.dylib 找到它,对于 iPhone,你会想要/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS4.0.sdk/usr/lib/libxml2.dylib版本.

Setting up your project file

You need to add libxml2.dylib to your project (don't put it in the Frameworks section). On the Mac, you'll find it at /usr/lib/libxml2.dylib and for the iPhone, you'll want the /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS4.0.sdk/usr/lib/libxml2.dylib version.

由于 libxml2 是一个 .dylib(不是一个友好的 .framework),我们仍然还有一件事要做.转到项目构建设置(项目->编辑项目设置->构建)并找到搜索路径".在标题搜索路径"中添加以下路径:

Since libxml2 is a .dylib (not a nice friendly .framework) we still have one more thing to do. Go to the Project build settings (Project->Edit Project Settings->Build) and find the "Search Paths". In "Header Search Paths" add the following path:

$(SDKROOT)/usr/include/libxml2

<小时>

另见OP的回答.

这篇关于libxml/tree.h 没有这样的文件或目录的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆