Re: GLib headers



Sebastian Wilhelmi <wilhelmi ira uka de> writes:

> Hi,
> 
> > > If the core developers approve, I would take care of getting that in. So
> > > Eric, just post the patch (better than that of course is to post a URL to
> > > the new headers as tar.gz, as a patch wouldn't make much sense here)
> > 
> > if you could take care of integrating that properly, i'd aprpechiate it.
> > for the current CVS version we do put stuff into a glib specific include
> > directory already, so its mostly a matter of splitting lgib.h up
> > appropriately.
> 
> Ok, I checked it in. Now we have lots of header files, all of which gets
> installed to /usr/include/glib-2.0. 
> 
> Originally I would have liked it to be /usr/include/glib-2.0/glib to avoid the
> application-seen name space pollution (#include <giochannel.h> vs. #include
> <glib/giochannel.h>), but that would have really been a mess to change. 

We need to do it, even if it is painful. The only problem I can think
of is the typical problem where <glib/guichannel.h> has to work before
instlalation - I think the best solution is to make a glib/ subdirectory
of glib and put the subheaders in there.

(#include <glib/glib.h> is not possible to do now, but that can be
left as a solitary exception, or we could even install glib.h in
two places.)
 
> But I would like to rename glib-object.h to gobject.h, is that possible, Tim,
> or was there some other reasoning behing that name other than avoiding
> gobject.h inside /usr/include?

If I recall my discussion with Tim, the concern was that gobject.h
should, by convention, be the file that includes the GObject definition,
and Tim wanted to avoid having two different gobject.h files.
 
> Also I would like to either move gmodule.h into glib/ or gthread into
> glib/gthread and gobject.h into glib/gobject to make it more consistent. 
> That should be best done by someone out there with actual write permission to
> CVS by moving the gmodule.c,v file to save the history. (Bad enough, we lost
> it for all the new header files)

Umm, I don't follow - you just said that everything was being installed
not in glib/...

> Additionally I don't see any strong reasons not to include gobject.h and
> gmodule.h per default into glib.h (as gthread.h already is). Alternativly we
> could NOT include gthread.h on default.

The main difference is that most of the thread functions can be used
(as noops) without including -lgthread, but the gmodule and gobject
functionality is contained in separate libraries.

Regards,                                        Owen




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