what needs the "hp" backend to autodetect printers?

Asked by Johannes Meixner

For background information see
https://bugzilla.novell.com/show_bug.cgi?id=546856

Summary:

I like to provide a RPM sub-package of HPLIP
which includes only what is needed for plain printing
with HPIJS and HPCUPS.

Therefore it includes
the hpijs binary,
the libraries libhpip and libhpmud,
the CUPS backend hp,
the CUPS filter foomatic-rip-hplip,
the CUPS filter hpcac,
the CUPS filter hpcups,
the CUPS filter hplipjs,
and all PPD files.

But when I have ony this installed, the "hp" backend
does no longer autodetect my HP LaserJet 1220 USB printer
but it also does not report any error message:
----------------------------------------------------
root@host # /usr/lib/cups/backend/hp
direct hp "Unknown" "HP Printer (HPLIP)"
----------------------------------------------------

After installing the rest of HPLIP, the "hp" backend
again autodetects my HP LaserJet 1220 USB printer:
----------------------------------------------------
root@host # /usr/lib/cups/backend/hp
direct hp:/usb/HP_LaserJet_1220?serial=00XXXXXXXXXX
 "HP LaserJet 1220"
 "HP LaserJet 1220 USB 00XXXXXXXXXX HPLIP"
 "MFG:HewLett Packard;
  MDL:HP LaserJet 1220;
  CLS:PRINTER;
  DES:HP LaserJet 1220;
  SN:00XXXXXXXXXX;"
----------------------------------------------------

Currently I don't know what in the rest of HPLIP
is needed by the "hp" backend for autodetection.

Therefore I like to ask HPLIP authors
what in the rest of HPLIP is needed
by the "hp" backend for autodetection.

Question information

Language:
English Edit question
Status:
Solved
For:
HPLIP Edit question
Assignee:
No assignee Edit question
Solved by:
Johannes Meixner
Solved:
Last query:
Last reply:
Revision history for this message
Johannes Meixner (jsmeix) said :
#1

Good that I asked such a silly question
because usually a short time after asking,
I had the great new idea to look at /var/log/messages
where all what I need was already nicely printed:
--------------------------------------------------
io/hpmud/model.c 108:
unable to open /etc/hp/hplip.conf: No such file or directory
io/hpmud/model.c 528:
no HP_LaserJet_1220 attributes found in /data/models/models.dat
--------------------------------------------------

Therefore I added /etc/hp/hplip.conf and
/usr/share/hplip/data/models/models.dat
to the RPM sub-package and guess what,
now the "hp" backend autodetects it!

Revision history for this message
David Suffield (david-suffield) said :
#2

Just a sugestion.

I would patch the hpijs static PPDs to use foomatic-rip instead of foomatic-rip-hplip. For a while now the latest foomatic-rip supports CUPSDDK generated PPDs so foomatic-rip-hplip is no longer needed.

Revision history for this message
Johannes Meixner (jsmeix) said :
#3

Hello David,
many thanks for your suggestion!

On the other hand I like to be "lazy on the safe side"
which means that I do not risk to find out for each
HPLIP version which special features in your PPDs
may require foomatic-rip-hplip so that I simply use
your PPDs "as is" and provide foomatic-rip-hplip too.

Of course when you at HPLIP do no longer have
foomatic-rip-hplip in your PPDs and/or when your
configure script might do "the right thing" automatically
I would just package it accordingly ;-)