...导入asimp,具体是:
#include <assimp/Importer.hpp>
#include <assimp/scene.h>
#include <assimp/postprocess.h>
和其他一些assimp标头。
我正在使用xcode 10.2.1。
我得到的错误:
我在与库一起安装的Link Binary with Libraries中导入了assimp brew install assimp
我重新安装了assimp brew reinstall assimp
,以防万一。
什么也没有变。Xcode仍然无法解决依赖关系。
I tried deleting the import the error is pointing on, but it just showed up at the next assimp import again, as in, xcode can't resolve the import, even though I added libassimp4.1.0.dylib
from /usr/local/Cellar/assimp/4.1.0/lib
. I'm lost here. This is supposed to work, but it doesn't. I imported other libs this way and never had an issue.
I fixed the compiler error by pointing xcode to the headers. It somehow didn't work with the homebrew installation, so I added this manually.
In your App settings, go to: build settings
scroll down to: search paths
there, find: header search paths
double click on it, then add by clicking +
add: /usr/local/Cellar/assimp/4.1.0/include
as non-recursive
根据不建议安装它的方式,或者不建议在系统范围内安装Homebrew(取决于是否安装),assimp可能位于其他目录中。就我而言/usr/local/Cellar/
本文收集自互联网,转载请注明来源。
如有侵权,请联系 [email protected] 删除。
我来说两句