Reputation: 129
I am getting the following errors when I try to compile my C++ OpenGL program in Xcode on Mac OS 10.8...What should I do?
Undefined symbols for architecture x86_64:
"_aglChoosePixelFormat", referenced from:
_main in main.o
"_aglCreateContext", referenced from:
_main in main.o
"_aglDestroyContext", referenced from:
_main in main.o
"_aglDestroyPixelFormat", referenced from:
_main in main.o
"_aglSetCurrentContext", referenced from:
_main in main.o
"_aglSetFullScreen", referenced from:
_main in main.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Upvotes: 0
Views: 1383
Reputation: 9392
Since you're using AGL, looking at the reference for AGL, you need to import the framework AGL along with OpenGL.
Upvotes: 1