On Saturday 14 June 2008 17:05:00 David E wrote:
To begin learning GTK, I submitted the following one line C program: #include <gtk/gtk.h> That received an error message. After looking in /usr/include, I tried: #include <gtk-2.0/gtk/gtk.h> That received several error messages. Tried editing all the included "gtk..." lines to "gtk-2.0...". That received floods of error messages.
What am I doing wrong? or is the SL 10.3 include file broken? All I want to do is key in the "helloworld.c" program on p. 16 of Andrew Krause's 2007 book "Foundations of GTK+ Development". Starting with a one line C program, just the #include statement, seemed easy enough, but it is not.
You need to have a few parameters on your gcc command line. The normal way is to get those from pkgconfig. Try gcc -o testgtk $(pkg-config --cflags gtk+-2.0) testgtk.c Anders --------------------------------------------------------------------- To unsubscribe, e-mail: opensuse-programming+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-programming+help@opensuse.org