I currently installed gtk2 through macport on os x 10.6 but when i tried to use library l开发者_Go百科ike
#include <gtk/gtk.h>
it still doesn't recognize it and give me compile errors. does anyone know how to install gtk2?
If you have pkg-config on your system, try:
pkg-config --cflags gtk+-2.0
MacPorts installs its header files and libraries in /opt/local/include
and /opt/local/lib
, respectively. Did you add -I/opt/local/include
and -L/opt/local/lib
to your compiler flags?
精彩评论