Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

installing gtk and glib

Tags:

linux

gtk

glib

hi every one kindly tell me how to install glib and gtk i am using ubuntu 10.04. i did;nt find any commands kindly tell me the procedure to install it

like image 793
tariq Avatar asked Mar 11 '11 15:03

tariq


People also ask

How do I get GTK on Linux?

In order to install GTK for GNU/Linux and Unix systems, you will need to get the GLib, GObject-Introspection, Pango, Gdk-Pixbuf, ATK and GTK packages to build GTK. To read more about these packages, please refer to the Architecture.


Video Answer


2 Answers

Simply type:

sudo apt-get install libgtk2.0-dev

glib is a dependency so it will be installed too. Also you might be interested in installing glade as i remember it installs a gtk reference too:

sudo apt-get install glade
like image 151
Fady Mohamed Othman Avatar answered Sep 28 '22 04:09

Fady Mohamed Othman


And once you install them with apt-get, you can easily look up how are they called in your library list using the following command:

pkg-config --list-all | grep query

You replace "query" with "glib" for example, in the result you can find:

glib-2.0 GLib - C Utility Library

So when you compile your code and you want to link your library with pkg-config, you can use this command:

gcc -o example example.c `pkg-config --libs --cflags glib-2.0`

like image 38
Marek Avatar answered Sep 28 '22 03:09

Marek