-
Open your browser at the Linuxprinting.org printer list
page.
-
Check the complete list of printers in the
database..
-
Select your model and click on the link.
-
You'll arrive at a page listing all drivers working with this
model (for all printers, there will always be
one
recommended driver. Try this one first).
-
In our case (HP LaserJet 4 Plus), we'll arrive at the default driver for the
HP-LaserJet 4 Plus.
-
The recommended driver is ljet4.
-
Several links are provided here. You should visit them all if you
are not familiar with the Linuxprinting.org database.
-
There is a link to the database page for the
ljet4.
On the driver's page, you'll find important and detailed information
about how to use that driver within the various available
spoolers.
-
Another link may lead you to the home page of the
author of the driver.
-
Important links are the ones that provide hints with
setup instructions for
CUPS;
PDQ;
LPD, LPRng, and GNUlpr);
as well as
PPR
or “spoolerless”
printing.
-
You can view the PPD in your browser through this link:
https://www.linuxprinting.org/ppd-o-matic.cgi?driver=ljet4&printer=HP-LaserJet_4_Plus&show=1
-
Most importantly, you can also generate and download
the
PPD.
-
The PPD contains all the information needed to use our
model and the driver; once installed, this works transparently
for the user. Later you'll only need to choose resolution, paper size,
and so on, from the Web-based menu, or from the print dialog GUI, or from
the command line.
-
If you ended up on the drivers
page,
you can choose to use the “PPD-O-Matic” online PPD generator
program.
-
Select the exact model and check either Download or
Display PPD file and click Generate PPD file.
-
If you save the PPD file from the browser view, please
do not use cut and paste (since it could possibly damage line endings
and tabs, which makes the PPD likely to fail its duty), but use in your browser's menu. (It is best to use the Download option
directly from the Web page.)
-
Another interesting part on each driver page is
the button. If you
select your printer model and click on that button,
a complete Ghostscript command line will be displayed, enumerating all options
available for that combination of driver and printer model. This is a great way to
“learn Ghostscript by doing”. It is also an excellent cheat sheet
for all experienced users who need to reconstruct a good command line
for that darned printing script, but can't remember the exact
syntax.
-
Sometime during your visit to Linuxprinting.org, save
the PPD to a suitable place on your hard disk, say
/path/to/my-printer.ppd
(if you prefer to install
your printers with the help of the CUPS Web interface, save the PPD to
the /usr/share/cups/model/
path and restart
cupsd).
-
Then install the printer with a suitable command line,
like this:
root#
lpadmin -p laserjet4plus -v parallel:/dev/lp0 -E \
-P path/to/my-printer.ppd
-
For all the new-style “Foomatic-PPDs”
from Linuxprinting.org, you also need a special CUPS filter named
foomatic-rip.
-
The foomatic-rip Perl script itself also makes some
interesting
reading
because it is well documented by Kamppeter's in-line comments (even
non-Perl hackers will learn quite a bit about printing by reading
it).
-
Save foomatic-rip either directly in
/usr/lib/cups/filter/foomatic-rip
or somewhere in
your $PATH (and remember to make it world-executable). Again,
do not save by copy and paste but use the appropriate link or the
menu item in your browser.
-
If you save foomatic-rip in your $PATH, create a symlink:
root#
cd /usr/lib/cups/filter/ ; ln -s `which foomatic-rip'
CUPS will discover this new available filter at startup after restarting
cupsd.