installing gtk and glib
Asked Answered
G

2

6

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

Guide answered 11/3, 2011 at 15:55 Comment(0)
T
16

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
Terrel answered 11/3, 2011 at 16:3 Comment(2)
thank u osman sir. i have types the command but its saying 7 hr remaining .is it fine i mean such large time thanksGuide
That's a very long time. If you have a slow internet connection then this might be the problem. If you have a fast connection you might try downloading the packages and their dependencies from packages.ubuntu.com and install them manually.Terrel
I
7

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`

Inverse answered 19/5, 2013 at 10:58 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.