I'm trying to install the GTK development environment on Ubuntu, and having difficulty simply get it installed.
Basically, my goal is to simply compile a C file which includes the header file <gtk/gtk.h>
, so I can start tinkering around:
#include <gtk/gtk.h>
int main() { }
So, this answer says you can simply apt-get install gnome-core-devel build-essential
to get the development environment installed. Okay, so I tried that and when I try to compile the above code, I get, the compiler complains it can't find the file gtk/gtk.h
So, I add /usr/include/gtk-2.0/
to the Path and compile again. Now it complains that it can't find another file /gio/gio.h
.
This file didn't even exist on my system, so after googling around for gio.h, and apt-getting other libraries, I managed to install it. I tried compiling again, this time the compiler can't find /usr/include/glib-2.0/glib/gtypes.h
.
At this point, I'm thinking it can't possibly be this difficult to simply install something like GTK development enviroment, which is a fairly popular package. I thought maybe something was wrong with my system, so I tried this on a different install of Ubuntu, and ran into the same issues.
So, what exact packages are necessary to install GTK? And will I need to manually configure my include path, or is that supposed to happen automatically?