Introduction to LPRng

The LPRng package contains an enhanced, extended and portable implementation of the Berkeley Line PRinter (LPR) print spooler. This is useful for queuing print jobs.

There may be a more recent release available from the LPRng home page. You can check http://sourceforge.net/projects/lprng and probably use the existing BLFS instructions. Note that versions other than the one shown in the download URLs have not been tested in a BLFS environment.

Package Information

LPRng Dependencies


OpenSSL-0.9.8g, TCP Wrapper-7.6, MIT Kerberos V5-1.6, and krb4

User Notes: http://wiki.linuxfromscratch.org/blfs/wiki/lprng

Installation of LPRng

Install LPRng by running the following commands:

sed -i    's@CLEAR,0@CLEAR,CLEAR,NULL@' src/common/lpq.c &&
sed -i    's@ fd, l@ fd, (char*) l@'    src/common/krb5_auth.c &&
sed -i -e 's@\(fi\|done\) \\@\1; \\@' \
       -e 's/^SHELL/#&/'                Makefile.in &&

./configure --prefix=/usr \
            --libexecdir=/usr/lib/lprng \
            --sysconfdir=/etc \
            --enable-shared &&

This package does not come with a test suite.

Now, as the root user:

make install &&
install -v -m755 -d /usr/share/doc/lprng-3.8.28 &&
cp -v -R DOCS/* PrintingCookbook \

Command Explanations

sed -i 's@CLEAR ...': This fixes a GCC-4 warning, treated as an error.

sed -i 's@ fd, l ...': This fixes a compilation problem with using versions of GCC-4.

sed -i -e '...' -e '...': This fixes a couple of syntax bugs when using newer versions of make.

Configuring LPRng

Config Files

/etc/printcap and /etc/lpd/*

Configuration Information

There is no generic printcap for all printers. A sample printcap is loaded into the /etc directory which can be of some help. Information is also available at http://www.lprng.org, http://www.linuxprinting.org and the documentation installed in /usr/share/doc/lprng-3.8.28.

Boot Script

The init script installed by LPRng is not consistent with other BLFS scripts; therefore, install the /etc/rc.d/init.d/lprng init script included in the blfs-bootscripts-20080816 package (as the root user):

make install-lprng


You may also want to remove the lpd script that was installed in /etc/rc.d/init.d.


Installed Programs: cancel, checkpc, lp, lpc, lpd, lpq, lpr, lprm, lprng_certs, lprng_index_certs, and lpstat
Installed Library: liblpr.{so,a}
Installed Directories: /etc/lpd, /usr/lib/lprng, /usr/share/doc/3.8.28, /var/run/lpd, and /var/spool/lpd

Short Descriptions


is a symlink to lprm used to send cancel requests to an LPRng print service.


checks out the printcap database.


is a symlink to lpr used to send requests to an LPRng print service.


is a control program for the lpd daemon.


is the print queueing daemon.


is a status monitoring program.


is a print job spooler program.


is a print job removal program.


is a program used to manage SSL certificates for the LPRng software.


creates a set of index files in the LPRng signing certificate directory.


is a print job status reporting program.


contains the API functions used by the LPRng programs.

Last updated on 2008-05-10 18:53:20 -0500