Bug 227047 - print/cups cups-genppd fails to generate for officejet_pro_8500_a909g and related models
Summary: print/cups cups-genppd fails to generate for officejet_pro_8500_a909g and rel...
Status: Closed Works As Intended
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Tijl Coosemans
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-03-28 19:00 UTC by freebsd
Modified: 2018-03-29 21:39 UTC (History)
0 users

See Also:
bugzilla: maintainer-feedback? (tijl)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description freebsd 2018-03-28 19:00:25 UTC
cups installs cups-genppd, which should be usable to generate ppd files.
However, it is missing the templates or ability to generate a ppd file for 
printers of type officejet_pro_8500_a909g.

cups-genppd -M -v does not list the printer

print/hplip lists the printer in its data/models/models.dat file, and
hp-setup (installed by hplip) can be used to generate a ppd file.

It is particularly painful to have to run down this chain to get a printer
to work.  Either cups should have no drivers and lots of pointers to where
to get them, or none at all.  It is particularly difficult because there are
three different ports that serve as sources for ppd files for hp printers -- cups, hplip, and hpijs; some printers appear in multiple ports.  Some, like the officejet pro 8500 a909 series, have no ppd files listed in any of the pkg-plists, because the file is only obtained by running hp-setup.  This means one has to dig through three different pkg-plists, then grep sources, to figure out where one *might* possibly get the required ppd file.  One must then install the port (hplip), read through its documentation and finally run a program to generate it.  The only clue that hplip is the right path is to grep its data/models/models.dat file.

I'm not sure what a good solution to this problem is.  Cups could install a list of packages containing ppd sources, and then when it can't find a ppd file at least can point the user at the appropriate ports.  The file could contain a short hint as will, such as "Try cups-genppd -M -v" and "grep /usr/ports/print/hpijs/pkg-plist" and whatever would be appropriate for cups itself.
Comment 1 commit-hook freebsd_committer freebsd_triage 2018-03-29 09:16:27 UTC
A commit references this bug:

Author: tijl
Date: Thu Mar 29 09:15:53 UTC 2018
New revision: 465874
URL: https://svnweb.freebsd.org/changeset/ports/465874

Log:
  Mark deprecated because having both hpijs and hplip can be confusing.

  PR:		227047

Changes:
  head/print/hpijs/Makefile
Comment 2 Tijl Coosemans freebsd_committer freebsd_triage 2018-03-29 09:31:27 UTC
cups-genppd is not part of cups, it's part of gutenprint and gutenprint probably does not support HP printers.  These days normally you don't need to worry about PPD files.  Just install the right driver (if you have an HP printer try the official HP driver in print/hplip), go to https://localhost:631 and add your printer.  You only need to select the printer model.  You don't need a PPD file.
Comment 3 freebsd 2018-03-29 15:31:00 UTC
For reference:

Gutenprint does in fact work with hp printers.  I use the gutenprint plugin from gimp with shop drawings on an hp printer.

While having both hpijs and hplip installed may be confusing, there may be occasions when one needs it (I'm not one of those; I'm simply pointing it out.) because there are printers found in hpijs which are not in hplip and vice-versa.  If one happened to have a combination of printers that each were found only in each of those, one would need both of them.  I have no idea how likely that is.
Comment 4 Tijl Coosemans freebsd_committer freebsd_triage 2018-03-29 16:41:43 UTC
(In reply to freebsd from comment #3)
HPIJS was at some point renamed HPLIP, so all printers supported by HPIJS should still be supported by HPLIP.  Do you have an example of a printer that isn't?
Comment 5 freebsd 2018-03-29 20:34:32 UTC
(In reply to Tijl Coosemans from comment #4)
Ah, ok.

Looking at the pkg-plists for the two ports, I see the following:
There may be some other driver that serves them.
I'm assuming some models with a letter on the end are served in hplip using a driver without the letter, although this is not obvious since there are many files that have the trailing letter.

HP-DesignJet_ColorPro_CAD-hpijs.ppd.gz
HP-DeskJet_350C-hpijs.ppd.gz        May be 350x?
HP-DeskJet_3528-hpijs.ppd.gz        May be 3520?
HP-DeskJet_3535-hpijs.ppd.gz
HP-DeskJet_3558-hpijs.ppd.gz        May be 3550?
HP-DeskJet_3658-hpijs.ppd.gz        May be 3650?
HP-DeskJet_3668-hpijs.ppd.gz
HP-DeskJet_3845-hpijs.ppd.gz        May be 3840?
HP-DeskJet_420C-hpijs.ppd.gz
HP-DeskJet_450-hpijs.ppd.gz         May be hp-dj450?
HP-DeskJet_5150-hpijs.ppd.gz
HP-DeskJet_5158-hpijs.ppd.gz
HP-DeskJet_5160-hpijs.ppd.gz
HP-DeskJet_5670-hpijs.ppd.gz
HP-DeskJet_5740-hpijs.ppd.gz
HP-DeskJet_6540-hpijs.ppd.gz
HP-DeskJet_6840-hpijs.ppd.gz
HP-OfficeJet_6110-hpijs.ppd.gz      May be 6100_series?
HP-OfficeJet_625-hpijs.ppd.gz
HP-OfficeJet_635-hpijs.ppd.gz       May be series_630?
HP-OfficeJet_7130-hpijs.ppd.gz
HP-OfficeJet_7140-hpijs.ppd.gz
HP-OfficeJet_Pro_1175C-hpijs.ppd.gz May be 1170?
HP-PSC_2110-hpijs.ppd.gz            May be 2100_series?
HP-PSC_2175-hpijs.ppd.gz            May be 2100_series?
HP-PSC_370-hpijs.ppd.gz
HP-PSC_380-hpijs.ppd.gz
HP-PhotoSmart_P100-hpijs.ppd.gz
HP-PhotoSmart_P1115-hpijs.ppd.gz
HP-PhotoSmart_P1215-hpijs.ppd.gz
HP-PhotoSmart_P1218-hpijs.ppd.gz
HP-PhotoSmart_P130-hpijs.ppd.gz
HP-PhotoSmart_P1315-hpijs.ppd.gz
HP-PhotoSmart_P230-hpijs.ppd.gz
HP-e-printer_e20-hpijs.ppd.gz
HP_LaserJet_5M.ppd.gz
Comment 6 Tijl Coosemans freebsd_committer freebsd_triage 2018-03-29 21:39:21 UTC
(In reply to freebsd from comment #5)
The first one indeed no longer seems to be supported (see https://developers.hp.com/hp-linux-imaging-and-printing/supported_devices/unsupported).  I haven't checked them all but some models don't seem to exist according to google, and others appear as aliases /usr/local/share/cups/drv/hpcups.drv.