LoranceChen
LoranceChen

Reputation: 2574

xcode can't load GLFW which compile by CMake

I follows the CMake org and this one attempt to load the library but failed.
I have use make install put GLFW to /usr/local/include/GLFW/, and then, I add the directory to Link Binary With Libraries in XCode project.
But #include <GLFW/glfw3.h> said the file not found.
How to load the library? thanks

Upvotes: 1

Views: 1690

Answers (1)

LoranceChen
LoranceChen

Reputation: 2574

It's my first time use cmake, I mess all things. To import the library should add /usr/local/include/ to Header Search Paths and add /usr/local/lib/ to Library Search Paths, besides, Link Binary With Libraries should add libglfw3.a in /usr/local/lib/.

import with #include <GLFW/glfw3.h>

Upvotes: 2

Related Questions