[clue-tech] Linux From Scratch

dennisjperkins at comcast.net dennisjperkins at comcast.net
Mon Jan 5 16:17:19 MST 2009


 -------------- Original message ----------------------
From: Bruce Ediger <eballen1 at qwest.net>
> On Mon, 5 Jan 2009, dennisjperkins at comcast.net wrote:
> 
> > Is anyone else in CLUE interested in building Linux from the ground up?  I'm
> > currently building Linux on a new laptop, using a mixture of LFS and DIY
> > Linux.
> 
> I am.  I've done LFS once, over a year ago, but I ditched it in favor of
> Slackware 12.0 for reasons I can't recall.  I bought a 40Gb maxtor at a 
> garage sale for $2, and I'm going to do LFS again, as soon as I can get
> the disk in the appropriate Pee Cee.
> 
> What's DIY linux?  Something even more from-scratch than LFS?
> 
> IBM's "developerWorks" had this tutorial:
> 
> http://www.ibm.com/developerworks/edu/l-dw-linux-embedded-distro-i.html
> _______________________________________________

I need to check out the link you sent.


DIY Linux is a similar project started by Greg Schafer after he and some of the LFS people had a falling out.  I built a DIY system a few years ago when I could not get LFS built one time, and LFS felt I was doing something wrong.  DIY built without a hitch, so I think LFS had a flaw in their build method.

My last system was actually Cross LFS.  I wanted to build a 64-bit system but the distros were mostly still 32-bit.  I used a 32-bit Suse to bootstrap my 64-bit CLFS.  The biarch is simply to let me build GRUB.  I have no intention of building any other 32-bit code, altho I suppose that could change.

Since then, Greg has added 64-bit and biarch capability to DIY.  I built a biarch DIY last week, except I used LFS's udev instead of MKDEV.  Now I am starting to build part of Beyond Linux From Scratch to get X.org and GNOME installed.  Personally, I think biarch is a PITA.  How many libraries should be biarch?  Or should all of them be biarch?  A few years ago, some packages didn't like biarch.

The BLFS part is going slowly, partly because I am carefully checking the results of each package by building it, and then using DESTDIR to install it into a temporary location.  If all of the files appear to be in the right location, I do a normal install.  Otherwise I modify my build script and try again.  This extra effort is mainly to make sure that the libraries install into /lib64 and /usr/lib64 and not in /lib and /usr/lib, as per LSB.

Occasionally, a package wants to install something in the wrong directory.  These are usually config files or libexec files.  These are usually fixed using --sysconfdir and --libexecdir directives.

DIY uses DESTDIR but LFS and BLFS, altho I think the next version of LFS might.  The advantage is that you can build packages, Debian, RPM or pacman, and they will install in the right location.  Unfortunately, a few packages don't use DESTDIR.   In those cases, you need to find another way to accomplish the same thing.


X.org could be more interesting than older versions.  The modularity makes builds more time-consuming altho the result is worth it.  But the ability to use D-bus to automatically configure X could be very handy.  The older method is still available too, and it looks like X.org uses D-bus to configure anything that xorg.conf doesn't provide information about.  I don't recall XCB from my last build either.


More information about the clue-tech mailing list