Xcode 4 (Lion) 上的 VTK 5.8
我试图在 OS X 下的 Xcode 上编译并启动 VTK 项目 狮子。 我按照此处的说明进行操作:http://www.vtk.org/Wiki/Cocoa_VTK 使用cmake下载并编译vtk(尽管我确实避免设置mac osx 部署目标为 10.4)
我认为,在新的 Xcode 项目下,我需要的只是设置 vtk 头文件搜索路径下的include文件夹,以及vtk下的lib文件夹 “其他链接器标志”。
但是我无法继续,Xcode 给了我一条错误消息: 'Command /Developer/usr/bin/clang failed with exit code 1'
以下是我的标头搜索路径: /Users/mycomp/VTKBuild/include/**
和其他链接器标志: /Users/mycomp/VTKBuild/lib/vtk-5.8
显然,当我清除“其他链接器标志”时,问题就消失了, 但这当然意味着我不再引用 VTK 的库了。
我有什么遗漏的吗?有没有关于如何进行更新的指南 在Xcode 4.0下启动VTK相关项目?
I was trying to compile and start with VTK project on my Xcode under OS X
Lion.
I followed the instructions here: http://www.vtk.org/Wiki/Cocoa_VTK to
download and compile vtk using cmake (although I did avoid setting the mac
osx deployment target to 10.4)
I presume that, under a new Xcode project, all I need is to set vtk's
include folder under the header search path, and vtk's lib folder under
'Other linker flags'.
However I am unable to proceed, Xcode gives me an error message:
'Command /Developer/usr/bin/clang failed with exit code 1'
Following is my header search path:
/Users/mycomp/VTKBuild/include/**
and other linker flags:
/Users/mycomp/VTKBuild/lib/vtk-5.8
Apparently the problem disappears when I clear out the 'Other linker flags',
but of course it means that I am not referring to VTK's library anymore.
Is there anything I am missing ? And is there any updated guide on how to
start on VTK-related project under Xcode 4.0 ?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
也许回答这个问题有点太晚了,但这似乎是一些奇怪的“其他链接器标志”。
我认为您可以将要链接的库添加到“构建阶段 - >将二进制与库链接”中,然后将库路径添加到“构建设置”下的“库搜索路径”中的包含文件夹。
如果您研究构建本身,您还可以获得有关失败原因的更多信息。
A bit too late to answer this perhaps, but that seems to be some strange "other linker flags".
I think you could just add the library you are linking with into "Build Phases -> Link Binary with libraries" and then add a library path to the containing folder in "Library search paths" under "Build settings".
You could also get more information about the reason behind the failure if you look into the build itself.