Click to See Complete Forum and Search --> : i have question about glib and gtk


roadorange
03-11-2004, 12:38 AM
i am using red hat linux 9.0, the glib and gtk are little old, and i downloaded glib-2.2.3 and gtk+-2.2.4
First, i extract glib in my personal direction, not those /lib or something. i install gblic successfully.
then i try to install gtk, here come the problem. when i compile the gtk, the result said glib 2.0 is not found.
here's some error report:

checking for glib-2.0 >= 2.1.4 atk >= 1.0.1 pango >= 1.0.1... Package glib-2.0 w
as not found in the pkg-config search path.
Perhaps you should add the directory containing `glib-2.0.pc'
to the PKG_CONFIG_PATH environment variable
No package 'glib-2.0' found

configure: error: Library requirements (glib-2.0 >= 2.1.4 atk >= 1.0.1 pango >=
1.0.1) not met; consider adjusting the PKG_CONFIG_PATH environment variable if y
our libraries are in a nonstandard prefix so pkg-config can find them.
[root@roadorange gtk+-2.2.4]# make
make: *** No targets specified and no makefile found. Stop.

what should i do now???@_@ does it really matter that i install the glib in my personal directory??
do i need to restart the computer after install glib

Stuka
03-11-2004, 01:53 PM
export PKG_CONFIG_PATH = $PKG_CONFIG_PATH:/path/to/directory/with/glib-2.0.pc

Just a thought - this SHOULD do what the makefile error asked you to do.

bwkaz
03-11-2004, 09:18 PM
You installed glib (NOT glibc btw!) into /usr/local, but pkg-config is only looking in /usr/lib/pkgconfig for the glib .pc file (that directory is its default search path; PKG_CONFIG_PATH is likely not even set).

Either install glib into /usr instead of /usr/local (pass --prefix=/usr to its configure script, and see the output of ./configure --help for other options), or export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig before running gtk's configure script.

But you'll also need ATK and Pango before Gtk 2 will install. They, in turn, require glib, so you're set there. You'll need to set their PKG_CONFIG_PATH's too, if you don't reinstall glib into /usr.

roadorange
03-18-2004, 12:45 PM
bwkaz. your reply is clear.
thanak you all. stuka and bwkaz. i will try them again. o^-^o