问题
I can't figure out how to add the framework to my project. I tried adding it like any other framework, by clicking the plus button under Link Binary With Libraries and then clicking 'other' and then selecting the GLM folder. But when I go to included it, the autocomplete works but it can't build because it says the file is not found.
Website for library: http://glm.g-truc.net/
回答1:
According to the website, it's not a framework, it's only headers. You should just add the headers directly to your project.
回答2:
If you are getting Match-O Link error make sure to remove/trash the core/dummy.cpp this will keep it from compiling.
回答3:
When I imported the headers in XCode 5, it tried to link glm.cpp and dummy.cpp automatically under build phase. I removed those and now I'm compiling.
Also had to rename all my files to *.mm to compile with obj-c++.
来源:https://stackoverflow.com/questions/8779430/how-do-i-add-opengl-mathematics-glm-to-xcode-4