facing errors while compiling GTK on Pardus
Here is a code below that I try to compile...
#include <gtk/gtk.h>
int main( int argc, char *argv[])
{
GtkWidget *window;
gtk_init(&argc, &argv);
window = gtk_window_new(GTK_WINDOW_TOPLEVEL);
gtk_widget_show(window);
gtk_main();
return 0;
}
This code seems very easy but error message while I try to compile isn't simple.
The error message is below;
**********************************************************************
compiling line:
gcc -Wall -g den1.c -o den1 `pkg-config --cflags gtk+-2.0 pkg-config --libs gtk+-2.0`
**********************************************************************
end result is too below:
Package xcb-shm was not found in the pkg-config search path.
Perhaps you should add the directory containing `xcb-shm.pc'
to the PKG_CONFIG_PATH environment variable
Package 'xcb-shm', required by 'cairo', not found
/tmp/ccGKXJ4V.o: In function `main':
/home/gurkan/Belgeler/gtkc-den/den1.c:7: undefined reference to `gtk_init'
/home/gurkan/Belgeler/gtkc-den/den1.c:9: undefined reference to `gtk_window_new'
/home/gurkan/Belgeler/gtkc-den/den1.c:10: undefined reference to `gtk_widget_show'
/home/gurkan/Belgeler/gtkc-den/den1.c:12: undefined reference to `gtk_main'
collect2: ld returned 1 exit status
***********************************************************
It mentions "you haven't library that its called "xcb-shm" or couldn't find location (but there isn't a packet in my system _ I'm using Pardus 2011). Are there anybody which facing similar problem like me?
|