[완료]GTK 설치 후 compile 시 error 입니다.
gtk 설치를 마치고..
hellow.c 를 컴파일 해보았습니다.
근데 다소 음.. 아래의 애러가 나오는데..
$ >> gcc -Wall -g hellow.c -o hellow `pkg-config --cflags gtk+-2.0`/tmp/cclMBxZ1.o: In function `hello':
/home/bubi/_temp/hellow.c:8: undefined reference to `g_print'
/tmp/cclMBxZ1.o: In function `delete_event':
/home/bubi/_temp/hellow.c:21: undefined reference to `g_print'
/tmp/cclMBxZ1.o: In function `destroy':
/home/bubi/_temp/hellow.c:33: undefined reference to `gtk_main_quit'
/tmp/cclMBxZ1.o: In function `main':
/home/bubi/_temp/hellow.c:45: undefined reference to `gtk_init'
/home/bubi/_temp/hellow.c:48: undefined reference to `gtk_window_new'
/home/bubi/_temp/hellow.c:55: undefined reference to `g_type_check_instance_cast'
/home/bubi/_temp/hellow.c:55: undefined reference to `g_signal_connect_data'
/home/bubi/_temp/hellow.c:61: undefined reference to `g_type_check_instance_cast'
/home/bubi/_temp/hellow.c:61: undefined reference to `g_signal_connect_data'
/home/bubi/_temp/hellow.c:65: undefined reference to `gtk_container_get_type'
/home/bubi/_temp/hellow.c:65: undefined reference to `g_type_check_instance_cast'
/home/bubi/_temp/hellow.c:65: undefined reference to `gtk_container_set_border_width'
/home/bubi/_temp/hellow.c:68: undefined reference to `gtk_button_new_with_label'
/home/bubi/_temp/hellow.c:73: undefined reference to `g_type_check_instance_cast'
/home/bubi/_temp/hellow.c:73: undefined reference to `g_signal_connect_data'
/home/bubi/_temp/hellow.c:79: undefined reference to `g_type_check_instance_cast'
/home/bubi/_temp/hellow.c:79: undefined reference to `gtk_widget_destroy'
/home/bubi/_temp/hellow.c:79: undefined reference to `g_type_check_instance_cast'
/home/bubi/_temp/hellow.c:79: undefined reference to `g_signal_connect_data'
/home/bubi/_temp/hellow.c:84: undefined reference to `gtk_container_get_type'
/home/bubi/_temp/hellow.c:84: undefined reference to `g_type_check_instance_cast'
/home/bubi/_temp/hellow.c:84: undefined reference to `gtk_container_add'
/home/bubi/_temp/hellow.c:87: undefined reference to `gtk_widget_show'
/home/bubi/_temp/hellow.c:90: undefined reference to `gtk_widget_show'
/home/bubi/_temp/hellow.c:95: undefined reference to `gtk_main'
pkgconfig가 잘못 된건지 이걸 바로 잡을 방법이 .. 못찾고 있습니다.
도움 부탁드립니다.
$>> pkg-config --cflags gtk+-2.0
-I/usr/local/include/gtk-2.0
-I/usr/local/lib/gtk-2.0/include -I/usr/local/include/atk-1.0 -I/usr/local/include/cairo -I/usr/local/include/pango-1.0 -I/usr/local/include/glib-2.0 -I/usr/local/lib/glib-2.0/include
$>>
gcc -Wall -g hellow.c -o
역시.... lib link 였던건가요..
감사합니다... ㅠ.ㅠ
허무하군요..
댓글 달기