BLFS Frequently Asked Questions

The FAQ is divided in three documents. The General FAQ has links to all questions and answers. The LFS FAQ is a selection of LFS-specific FAQ's and the BLFS FAQ is a selection of BLFS-specific FAQ's.

General BLFS questions

Compilation issues

Configuration issues

General BLFS questions

How do I make a bootable CD?

The LFS LiveCD Project has already done the dirty work! The project has a documentation page. Information about how to obtain the project's makefiles, scripts and configurations are available on the download page.

If that doesn't interest you, there are several hints related to boot CD's.

Where do I join the LFS SETI/Predictor/etc team?

[email protected]: Join Team LFS

[email protected]: Team LFS Page

Back to the top.

Compilation issues

I'm getting errors building a package that requires GTK+, but I've installed GTK+ 2.x.

GTK+ 2.x and 1.2.x aren't compatible. The package you're installing may need GTK+ (and GLIB) 1.2.x. You can install GTK+ (and GLIB) 1.2.x next to 2.x.

undefined reference to `deflate'

If, when compiling XFree86, ghostscript, or anything else that uses libpng, you get an error including the following line:/usr/lib/gcc-lib/i686-pc-linux-gnu/3.2/../../../ undefined reference to `deflate'.

Then rebuild libpng with the patch at Make sure you apply the patch immediately after unpacking the sources. Like this:

tar --no-same-owner -xvjf libpng-1.2.5.tar.bz2
cd libpng-1.2.5
cat ../libpng-1.2.5-lz.patch | patch -p0
ln -s scripts/makefile.linux Makefile
make ZLIBLIB=/lib ZLIBINC=/usr/include
make ZLIBLIB=/lib ZLIBINC=/usr/include install
cd ..
rm -r libpng-1.2.5

Needless to say, if you originally put zlib in /usr/local or did something else different, you'll have to adjust those instructions accordingly.

X11/Xlib.h: No such file or directory

Typical symptoms look like this:

$ echo -en 'x11:\n\tgcc x11.c\n' > Makefile
$ echo -en '#include <X11/Xlib.h>\nmain() { }\n' > x11.c
$ make
gcc x11.c
x11.c:1: X11/Xlib.h: No such file or directory
make: *** [x11] Error 1
$ rm Makefile x11.c

Creating a couple symlinks will fix it. Here are the commands:

cd /usr
ln -s X11R6 X11
cd include
ln -s ../X11/include/X11 X11

Any error while building part of Gnome

Using the latest version of every Gnome package doesn't work. You have to use versions that are known to work together and are used in the BLFS book.

To find a list of such versions go to, drill down to the version which is mentioned in BLFS and use those.

XFree86: Makefile.proto:32: *** missing separator

If you get the following error while building XFree86:

Makefile.proto:32: *** missing separator. Stop.

Or something which resembles that, you've probably made a mistake in your host.def. Check the file carefully for errors and try recreating it by copying the example in BLFS.

Back to the top.

Configuration issues

How do I print?

See one of the various printing hints

Before you try any of the advanced printer daemons (for example CUPS) make sure your printer works by following the Printing From Scratch hint. For most people, this hint is all that is required to setup basic printing.

When reporting problems with CUPS, please indicate whether the following commands work:

# This is an image, so ghostscript is not called
lpr -o ppi=100 /usr/share/doc/cups/images/cups-block-diagram.gif
# This PostScript file doesn't use any fonts
lpr /usr/share/ghostscript/<version>/examples/
# This PostScript file uses fonts
lpr /usr/share/ghostscript/<version>/examples/

How do I set PS1 in Konsole?

Follow the instructions on the BLFS Bash Shell Startup Files to properly setup your enviroment.

Alternatively, you can try the following solutions:

Start konsole as a login shell:

konsole --ls

Change the session in Konsole to start /bin/bash --login instead of /bin/bash.