You are not logged in.
$ cat >> test.c << "EOF"
># include <gtk/gtk.h>
>int main (int argc, char **argv)
>{
> return 0;
>}
>EOF
$ gcc test.c
this simple peice of code does not compile due to complaints about missing header files. my gtk.h is in /usr/include/gtk-{1.2,2.0}/, and when I use the -I switch to specify the search path this file is found...but header files referenced within gtk.h are then said to be unavailable. I have to add a long list of -I switches to get around this problem at the moment. Isn't there some sort of env var I can set to get around this? I have gtk-1.2 and gtk-2.0 installed (hence the bash notation above) on my machine, is there a way to prevent apps from confusing the gtk.h of one version with another?
Thank you much
Offline
The classic command line to compile a GTK+ based program is
gcc -o myprog [c files] `pkg-config gtk+-2.0 --cflags --libs`
Maybe you can do something linke pkg-config gtk+-1.0?
Hail to the thief!
Offline
Very much thanks! I am relatively new to Linux (hence the newb section) and attempting to re-learn my programming skills in this new environment out of a book - but they don't say "If pkg-config is unavailable then do such and such...". I figured since it wasn't installed by default that there must have been an arch way to do things, however, after your suggestion I ran `pacman -Sy pkgconfig` and it works just fine. I assume it was my error that pkg-config wasn't installed by default, so color me blundered (awesome). - distro and community continues to make me smile, hopefully after a few more of my uglies ill give a bit back.
GTK FAQ ... indeed.
Offline