Hko is absolutely correct. A couple of additional notes:
1. If your "gtk.h" header is in "/usr/include/gtk-1.2/gtk/gtk.h", then:
a) Your source file must read "#include <gtk/gtk.h>"
... and ...
b) Your "-I" compile switch must point to the gtk/ directory and not the gtk.h header:
2. You should be able to use "gtk-config --cflags" to get the correct GTK+ compile
flags ... and "gtk-config --libs" for the GTK+ link flags ... and "glib-config --cflags" for
the Glib compile flags ... etc etc
Just FYI, in GTK+2 all the individual "*-config" scripts have been replaced with
a single "pkg-config" script.
If you prefer, you can also just hard-code the correct flags into your makefile. In
some cases, this might actually be easier and more effective than debugging
the *config" scripts.
3. You might have different GTK+ headers in different directories. For example, on my
SuSE system, I have some of the GTK+ headers in /usr/include ... and others in
/usr/lib/gtk*/include. So you might need multiple different "-I" switches (and, when
you're past the compile errors, multiple different "-L" link siwtches).
4. Look at the *first* compile error, at the top of the errors. That will be the most important
to understand the actual problem.
'Hope that helps .. PSM