Re: pkg-config v/s gtk-config


gtk+-1.2 and gtk+-2.0 aren't compatible, you cannot just replace
gtk+-1.2 with gtk+-2.0 and recompile (ie the application must have been
ported to gtk+-2.0, and in that case, the developpers will modify the
configure script so that it will invoke pkg-config properly)

For example, gimp-1.3.x (unstable developpment branch) uses gtk+2.0
while gimp 1.2.x (stable branch) still uses gtk+-1.2

If you plan to port your application to gtk+-2.0, you can use 

    CFLAGS=`pkg-config gtk+-2.0 --cflags`
    LIBS=`pkg-config gtk+-2.0 --libs`

in place of gtk+-1.2 that was invoked like :

    CFLAGS=`gtk-config --cflags`
    LIBS=`gtk-config --libs`

in your Makefile. But, usually, porting an application to gtk+-2.0 is a
lot more than just replacing the compilation flags ;-)

Hope that helps, 


On Thu, 2002-09-12 at 16:14, Dirk Will wrote:
> Hi there,
> I installed gtk+-2.0.6 and now I want to install some more packages like
> gimp, gaim and so on.
> As i am running (for example):
> "./configure --prefix=/opt/pd/Programme/gimp-1.2.3 --enable perl --enable
> python"
> all i receive is a message like:
> checking for GTK - version >= 1.2.8... no
> *** The gtk-config script installed by GTK could not be found
> *** If GTK was installed in PREFIX, make sure PREFIX/bin is in
> *** your path, or set the GTK_CONFIG environment variable to the
> *** full path to gtk-config.
> configure: error: Test for GTK failed. See the file 'INSTALL' for help.
> well, the INSTALL file is still talking about gtk-config...
> as i found out in the web after a long stroll today i have to use pkgconfig
> instead. But how?
> It wont work like 
> "pkg-config --libs --cflags gtk+-2.0.6 > ./configure
> --prefix=/opt/pd/Programme/gimp-1.2.3 --enable-perl --enable-python"
> or just running the pkg_config string 
> "pkg-config --libs --cflags gtk+-2.0.6"
> and after it the configure string.
> The pages i found all tell me to use pkg-config, but not how to use it
> together with configure.
> I have set the Path Variables and so on, like
> LD_LIBRARY_PATH, PKG_CONFIG_PATH, CPP_FLAGS that i have found in the various
> README and INSTALL Files, but how to tell the configure to use the
> infromation of pkgconfig?
> That question is propably very trivial for the most of you, on the other
> hand i didn't find any answer nowhere but more often some other asking questions
> in that direction.
> Anyway, thanks a lot....
> Bye, Dirk.
> -- 
> GMX - Die Kommunikationsplattform im Internet.
> _______________________________________________
> gtk-devel-list mailing list
> gtk-devel-list gnome org
Olivier               <fourdan xfce org>  
XFce is a lightweight  desktop  environment  for  various *NIX systems.
Designed for productivity,  it loads  and  executes  applications fast,
while conserving  system resources. XFce is all free software, released
under GNU General Public License.    Available from

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]