0

当我尝试在 Mac OS 10.8 上的 Xcode 中编译我的 C++ OpenGL 程序时出现以下错误...我该怎么办?

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)
4

1 回答 1

1

由于您使用的是 AGL,因此查看AGL的参考,您需要将框架 AGL 与 OpenGL 一起导入。

于 2013-01-13T14:52:46.290 回答