Re: [gtk-list] Red Hat's gtk+-devel-1.0.4-1

//Red Hat's Gtk+-devel rpm 1.0.4 version 1 places the include file glibconfig.h 
//in the directory /usr/lib/glib/include/ where, at least on my system, gcc and 
//egcs can't find it.  It does, on the other hand, place glib.h in/usr/include. 
//This created an obscure problem whenever I tried to compile something because 
//it appeared that the header glibconfig.h was missing.  I solved this problem 
//by making a symlink in /usr/include to glibconfig.h (once I'd found the 
//thing), but I couldn't find this problem with the package listed in Red Hat's 
//errata so I thought this might be a good place to report it?

See the FAQ, question 2.6:

2.6 When compiling programs with GTK+, I get compiler error messages about not 
being able to find "glibconfig.h".

The header file "glibconfig.h" was moved to the directory 
$exec_prefix/lib/glib/include/. $exec_prefix is the directory that was 
specified by giving
the --exec-prefix flags to ./configure when compiling GTK+. It defaults to 
$prefix, (specified with --prefix), which in turn defaults to /usr/local/.

This was done because "glibconfig.h" includes architecture dependent 
information, and the rest of the include files are put in $prefix/include, which
can be shared between different architectures. 

GTK+ includes a shell script, gtk-config, that makes it easy to find out the 
correct include paths. The GTK+ tutorial includes an example of
using gtk-config for simple compilation from the command line. For information 
about more complicated configuration, see the file
docs/gtk-config.txt in the GTK+ distribution. 

If you are trying to compile an old program, you may be able to work around the 
problem by configuring it with a command line like:

     CPPFLAGS="-I/usr/local/include/glib/include" ./configure

for Bourne-compatible shells like bash, or for csh variants: 

     setenv CPPFLAGS "-I/usr/local/include/glib/include" 

(Substitute the appropriate value of $exec_prefix for /usr/local.) 


"FLASH!  Intelligence of mankind decreasing.  Details at ... uh, when
 the little hand is on the ...." -- Jarek Luberek

How do I connect to that real-life thing I keep hearing about?

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