On Thu, 22 Mar 2012 18:27:25 +0000
LM <[email protected]> wrote:

> Am attempting to build the glib and the gtk libraries.  I built libffi
> which glib requires.  I noticed libffi puts its include files under
> the lib directory and not under the usual include directory.  The blfs
> information leaves the files where they are.  I checked the Debian
> patches to see how they place their files and they move the files to
> the standard include directory.  So, I tried building and moving the
> include files there.  Then I tried building glib and all files ended
> up in the standard include directory except one, glibconfig.h, which
> ends up in lib\glib-2.0\include\.  Checked the Debian patches and they
> don't move this one to the standard include directory.  Tried
> searching on Google and saw some mention that moving the file could
> mess up cross-compilers, but in that example the file wasn't exactly
> under lib\glib-2.0\include but was under lib\triplet\glib-2.0\include.
>  Is there a standard for this?  Should library include files end up in
> a common include directory or should they end up under
> lib\name_of_lib\include.  Is there a rule when they should go to one
> place as opposed to another.  I don't mind moving the files around,
> I'm just trying to find a consistent approach to where my include
> files end up that makes sense.  Does anyone have any input on why to
> do it one way as opposed to another or how to make this more
> consistent?

It's up to you. Your system, your rules. On my systems I try to put all
the headers into /usr/include. With libffi I use these commands:
sed -i 's#${libdir}/#/usr/include/#;s#/include$##' libffi.pc.in
sed -i 's#sdir = $(libdir)#sdir = /usr/include#;s#/include$##' \
  include/Makefile.in

With glib:
sed -i 's:lib\(dir)/glib-2.0\)/\(include\):\2\1:' glib/Makefile.in
sed -i 's/0 .* /0 /' glib-2.0.pc.in

For gtk2:
sed -i 's:lib\(dir)/gtk-2.0\)/\(include\):\2\1:' gdk/Makefile.in
sed -i 's/0 .* /0 /' gdk-2.0.pc.in

But there are other things that I've not got round to fixing (gcc and
perl) 'cos they're too complicated and the only benefit is to satisfy
my obsessive-compulsive tendencies. One day...

Andy
-- 
http://linuxfromscratch.org/mailman/listinfo/blfs-support
FAQ: http://www.linuxfromscratch.org/blfs/faq.html
Unsubscribe: See the above information page

Reply via email to