Bug 207746 - [exp-run] Overhaul of print/cups and related ports
Summary: [exp-run] Overhaul of print/cups and related ports
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Ports Framework (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Tijl Coosemans
URL:
Keywords:
Depends on:
Blocks: 205179 164293 186021 188376 190434 193636 195841 196806 197357 198777 200795 203053 203058 204027 207024
  Show dependency treegraph
 
Reported: 2016-03-06 14:09 UTC by Tijl Coosemans
Modified: 2016-03-11 12:00 UTC (History)
7 users (show)

See Also:


Attachments
patch (340.41 KB, patch)
2016-03-06 14:09 UTC, Tijl Coosemans
no flags Details | Diff
patch2 (340.25 KB, patch)
2016-03-06 17:19 UTC, Tijl Coosemans
no flags Details | Diff
patch3 (350.71 KB, patch)
2016-03-08 18:39 UTC, Tijl Coosemans
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Tijl Coosemans freebsd_committer 2016-03-06 14:09:38 UTC
Created attachment 167765 [details]
patch

Short description:
The attached patch combines print/cups-base, print/cups-client and print/cups-image into print/cups and updates it to 2.1.3 plus several improvements.  It also removes print/cups-pstoraster, improves print/cups-filters, print/foomatic-* and updates print/hplip to 3.16.2.

Long description:
First some background.  When you hand a file to cups it sets up a chain of filter programs that converts the file to something a printer understands.  Each filter has a cost associated with it and cups tries to find the cheapest chain.  Costs used to be configured in such a way that files were first converted to PostScript.  This could then be manipulated further (e.g. putting multiple pages on one sheet) before finally being sent to a PostScript printer or another filter like pstoraster which produces a raster format understood by non-PostScript printer drivers.  Nowadays most filters have been moved from cups to cups-filters and they have been configured to use PDF as an intermediate format instead of PostScript.  See http://www.linuxfoundation.org/collaborate/workgroups/openprinting/pdf_as_standard_print_job_format for more details.

Merging of cups-base, cups-client and cups-image into print/cups.
cups-image provides a library to work with the cups raster format.  It is only used to implement filters and printer drivers and these only exist in the context of a cups server so there's no need to separate this from cups-base.
cups-client provides a library that allows applications to print via cups.  It is possible to use the library to access a remote cups server without running a local cups server, but such a setup is discouraged and the configuration file to set this up has been marked deprecated (https://cups.org/documentation.php/doc-2.1/man-client.conf.html).  It is better to run a local cups server and let that talk to the remote cups server because then you have the benefits of local job queuing in case the remote server is down or busy.  Given this and the fact that without filters cups-base is now smaller than it used to be it makes sense to merge the ports.  The patch also adds options IPPTOOL, DOCS and NLS which when disabled make the new cups package smaller than the current cups-client package.  Merging the ports also prevents problems with options like ZEROCONF being configured differently in both ports.
print/cups is currently a metaport that depends on cups-base and some filters.  There isn't really a need for such a metaport I think so cups-base can be renamed to cups.  The filters can be depended on by printer drivers such as hplip if they need them.
Additional changes to the new print/cups:
- Update to 2.1.3.
- Clean up the patches.  They seem to have been regenerated with post-patch changes included.
- Add a patch to prevent intermediate conversion to PDF when a PostScript file is sent to a PostScript printer when cups-filters is installed.
- Fix the PAM configuration file.
- Add a patch to let the server search /usr/local/share/ppd like on Linux so other ports don't have to add links to it from /usr/local/share/cups/model.
- Remove ulpt(4) helper scripts.  The port uses libusb with ugen(4).
- Remove support for mDNSResponder.  cups-filters only supports Avahi.
- Combine ICONS and XDG_OPEN options into an X11 option to support WITHOUT_X11.
- Optionally depend on colord for ICC profile support.
- Various smaller changes.

print/cups-filters:
- Let the cups_browsed rc.d script depend on avahi_daemon.
- Development of foomatic-filters has been moved to cups-filters so let this port install foomatic related files and add foomatic-filters to CONFLICTS.
- Fix location of liblouis tables.
- Add patch to fix ICC support.

print/cups-pstoraster:
This port is essentially an old version of Ghostscript plus a cups filter.  It's no longer developed.  The patch removes it and changes existing dependencies to print/cups-filters which depends on print/ghostscript* and includes a gstoraster filter that can handle both PostScript and PDF.

print/foomatic-db*:
Remove old MASTER_SITES and dependencies and eliminate PKGNAMEPREFIX.

print/foomatic-filters:
Install beh backend with its original name again and add cups-filters to CONFLICTS.

print/hplip:
- Update to 3.16.2.
- Stop installing foomatic support.  This is no longer supported upstream and is outdated (foomatic 3.x).
- Stop installing hpijs.  This is no longer supported.
- Stop installing hpcups PPDs.  These are now automatically generated.  The bundled PPDs are generated for an older cups version.
- Install dbus, hal and policykit support files.
- Rename the QT option to X11 to support WITHOUT_X11.
- Simplify the patches now that ports are installed in a staging area.
- Add a patch to set SO_REUSEPORT (next to SO_REUSEADDR) on the mDNS socket like avahi-daemon does.  This fixes Zeroconf support for HP network printers.
Comment 1 Antoine Brodin freebsd_committer 2016-03-06 16:16:28 UTC
Exp-run failed to start:

[00:02:51] ====>> Error: Dependency loop detected:
These packages depend on each other: tex-xmltex-1.9_2 tex-formats-20150521_2 texlive-texmf-20150523_3 texlive-base-20150521_7 ghostscript9-base-9.06_12 cups-2.1.3 colord-1.2.11 docbook-utils-0.6.14_13 tex-jadetex-3.13_3
Comment 2 Naram Qashat 2016-03-06 16:24:05 UTC
I'm fine with the changes to cups-filters. Very impressive overhaul here.
Comment 3 Tijl Coosemans freebsd_committer 2016-03-06 17:19:49 UTC
Created attachment 167769 [details]
patch2

Remove COLORD option from print/cups for now.  It's only a run dependency.  Cups detects via DBus if the Colord service is available or not.
Comment 4 Antoine Brodin freebsd_committer 2016-03-07 21:14:48 UTC
Exp-run results on 10.3 i386:

http://package22.nyi.freebsd.org/build.html?mastername=103i386-default-PR207746&build=2016-03-06_18h47m04s

There are 4 new failures:

+ {"origin"=>"print/foomatic-filters", "pkgname"=>"foomatic-filters-4.0.17_6", "phase"=>"configure", "errortype"=>"???"}
+ {"origin"=>"print/hplip-plugin", "pkgname"=>"hplip-plugin-3.14.10", "phase"=>"stage", "errortype"=>"???"}
+ {"origin"=>"print/linux-c6-cups-libs", "pkgname"=>"linux-c6-cups-libs-1.4.2_4", "phase"=>"stage", "errortype"=>"???"}
+ {"origin"=>"print/linux-f10-cups-libs", "pkgname"=>"linux-f10-cups-libs-1.3.11_1", "phase"=>"stage", "errortype"=>"???"}

Failure logs:

http://package22.nyi.freebsd.org/data/103i386-default-PR207746/2016-03-06_18h47m04s/logs/errors/foomatic-filters-4.0.17_6.log
http://package22.nyi.freebsd.org/data/103i386-default-PR207746/2016-03-06_18h47m04s/logs/errors/hplip-plugin-3.14.10.log
http://package22.nyi.freebsd.org/data/103i386-default-PR207746/2016-03-06_18h47m04s/logs/errors/linux-c6-cups-libs-1.4.2_4.log
http://package22.nyi.freebsd.org/data/103i386-default-PR207746/2016-03-06_18h47m04s/logs/errors/linux-f10-cups-libs-1.3.11_1.log
Comment 5 Antoine Brodin freebsd_committer 2016-03-07 22:12:51 UTC
On 9.3 there is an extra failure:

+ {"origin"=>"print/cups-filters", "pkgname"=>"cups-filters-1.8.2_1", "phase"=>"configure", "errortype"=>"configure_error"}

Failure log:

http://package23.nyi.freebsd.org/data/93amd64-default-PR207746/2016-03-06_18h47m02s/logs/errors/cups-filters-1.8.2_1.log
Comment 6 Naram Qashat 2016-03-08 00:39:00 UTC
The problem with cups-filters on 9.3 looks more like a problem with libqpdf, from what I can see in the build log.
Comment 7 Tijl Coosemans freebsd_committer 2016-03-08 18:39:59 UTC
Created attachment 167866 [details]
patch3

- Delete some patches in foomatic-filters.
- Disable policykit support in hplip again.  This is only needed to let hplip download and install hplip-plugin at runtime, but this means files are installed that aren't under pkg control.
- Add 022 to some umask calls in hplip to fix some file permissions.
- Update hplip-plugin to 3.16.2.
- Fix DESCR in linux-*-cups-libs.
- Patch libqpdf pkgconfig file for FreeBSD 9 which doesn't provide zlib.pc.
Comment 8 Antoine Brodin freebsd_committer 2016-03-09 16:01:32 UTC
Exp-run was fine.
Comment 9 Tijl Coosemans freebsd_committer 2016-03-09 17:15:01 UTC
Thanks.  Does anyone have any final comments?
Comment 10 commit-hook freebsd_committer 2016-03-11 09:23:11 UTC
A commit references this bug:

Author: tijl
Date: Fri Mar 11 09:22:53 UTC 2016
New revision: 410816
URL: https://svnweb.freebsd.org/changeset/ports/410816

Log:
  Delete print/cups before renaming print/cups-base.  This is just a metaport
  for various cups components that will no longer be needed.

  PR:		207746

Changes:
  head/MOVED
  head/print/Makefile
  head/print/cups/
Comment 11 commit-hook freebsd_committer 2016-03-11 11:54:25 UTC
A commit references this bug:

Author: tijl
Date: Fri Mar 11 11:53:46 UTC 2016
New revision: 410825
URL: https://svnweb.freebsd.org/changeset/ports/410825

Log:
  Combine print/cups-base, print/cups-client and print/cups-image into
  print/cups and update it to 2.1.3.  Also remove print/cups-pstoraster,
  improve print/cups-filters, print/foomatic-* and update print/hplip to
  3.16.2.

  Long description:

  First some background.  When you hand a file to cups it sets up a chain of
  filter programs that converts the file to something a printer understands.
  Each filter has a cost associated with it and cups tries to find the
  cheapest chain.  Costs used to be configured in such a way that files were
  first converted to PostScript.  This could then be manipulated further (e.g.
  putting multiple pages on one sheet) before finally being sent to a
  PostScript printer or another filter like pstoraster which produces a raster
  format understood by non-PostScript printer drivers.  Nowadays most filters
  have been moved from cups to cups-filters and they have been configured to
  use PDF as an intermediate format instead of PostScript.

  Merging of cups-base, cups-client and cups-image into print/cups:
  - cups-image provides a library to work with the cups raster format.  It is
    only used to implement filters and printer drivers and these only exist
    in the context of a cups server so there's no need to separate this from
    cups-base.
  - cups-client provides a library that allows applications to print via cups.
    It is possible to use the library to access a remote cups server without
    running a local cups server, but such a setup is discouraged and the
    configuration file to set this up has been marked deprecated.  It is
    better to run a local cups server and let that talk to the remote cups
    server because then you have the benefits of local job queuing in case the
    remote server is down or busy.  Given this and the fact that without
    filters cups-base is now smaller than it used to be it makes sense to
    merge the ports.  The patch also adds options IPPTOOL, DOCS and NLS which
    when disabled make the new cups package smaller than the current
    cups-client package.  Merging the ports also prevents problems with
    options like ZEROCONF being configured differently in both ports.
  - print/cups was a metaport that depended on cups-base and some filters.
    There isn't really a need for such a metaport so cups-base can be renamed
    to cups.  The filters can be depended on by printer drivers such as hplip
    if they need them.

  Additional changes to the new print/cups:
  - Clean up the patches.  They seem to have been regenerated with post-patch
    changes included.
  - Add a patch to prevent intermediate conversion to PDF when a PostScript
    file is sent to a PostScript printer when cups-filters is installed.
  - Fix the PAM configuration file.
  - Add a patch to let the server search /usr/local/share/ppd like on Linux so
    other ports don't have to add links to it.
  - Remove ulpt(4) helper scripts.  The port uses libusb with ugen(4).
  - Remove support for mDNSResponder.  cups-filters only supports Avahi.
  - Combine ICONS and XDG_OPEN options into an X11 option to support WITHOUT_X11.
  - Optionally depend on colord for ICC profile support.
  - Various smaller changes.

  Changes to print/cups-filters:
  - Let the cups_browsed rc.d script depend on cupsd and avahi_daemon instead
    of LOGIN.
  - Development of foomatic-filters has been moved to cups-filters so let this
    port install foomatic related files and add foomatic-filters to CONFLICTS.
  - Fix location of liblouis tables.
  - Add patch to fix ICC support.

  Changes to print/cups-pstoraster:
  This port is essentially an old version of Ghostscript plus a cups filter.
  It's no longer developed.  This commit removes it and changes existing
  dependencies to print/cups-filters which depends on print/ghostscript* and
  includes a gstoraster filter that can handle both PostScript and PDF.

  Changes to print/foomatic-db*:
  Remove old MASTER_SITES and dependencies and eliminate PKGNAMEPREFIX.

  Changes to print/foomatic-filters:
  Install beh backend with its original name again and add cups-filters to
  CONFLICTS.

  Changes to print/hplip:
  - Stop installing hpijs/foomatic-rip support.  This is no longer supported
    upstream.
  - Stop installing hpcups PPDs.  These are now automatically generated.  The
    bundled PPDs are generated for an older version of cups.
  - Rename the QT option to X11 to support WITHOUT_X11.
  - Simplify the patches now that ports are installed in a staging area.
  - Add a patch to set SO_REUSEPORT (next to SO_REUSEADDR) on the mDNS socket
    like avahi-daemon does.  This fixes Zeroconf support for HP network
    printers.

  PR:		207746
  Exp-run by:	antoine
  Approved by:	portmgr (antoine)

Changes:
  head/MOVED
  head/UPDATING
  head/editors/libreoffice/Makefile
  head/editors/libreoffice4/Makefile
  head/editors/openoffice-4/Makefile
  head/editors/openoffice-devel/Makefile
  head/emulators/wine/Makefile
  head/emulators/wine-devel/Makefile
  head/games/pythonsudoku/Makefile
  head/graphics/darktable/Makefile
  head/graphics/epdfview/Makefile
  head/graphics/oyranos/Makefile
  head/java/openjdk6/Makefile
  head/java/openjdk7/Makefile
  head/java/openjdk8/Makefile
  head/net/freerdp/Makefile
  head/net/opennx/Makefile
  head/net/samba36/Makefile
  head/net/samba41/Makefile
  head/net/samba42/Makefile
  head/net/samba43/Makefile
  head/net/x2goclient/Makefile
  head/print/Makefile
  head/print/cups/
  head/print/cups/Makefile
  head/print/cups/distinfo
  head/print/cups/files/cups
  head/print/cups/files/cupsd.in
  head/print/cups/files/patch-conf-Makefile
  head/print/cups/files/patch-conf_mime.convs.in
  head/print/cups/files/patch-configure
  head/print/cups/files/patch-data-Makefile
  head/print/cups/files/patch-data_cups.pam
  head/print/cups/files/patch-scheduler_Makefile
  head/print/cups/files/patch-scheduler__auth.c
  head/print/cups/files/patch-scheduler_auth.c
  head/print/cups/files/patch-scheduler_cups-driverd.cxx
  head/print/cups/files/ulpt-cupsd.conf.in
  head/print/cups/files/ulpt-cupsd.sh.in
  head/print/cups/pkg-descr
  head/print/cups/pkg-descr.client
  head/print/cups/pkg-descr.image
  head/print/cups/pkg-message
  head/print/cups/pkg-plist
  head/print/cups/pkg-plist.client
  head/print/cups/pkg-plist.image
  head/print/cups-base/
  head/print/cups-bjnp/Makefile
  head/print/cups-client/
  head/print/cups-cloud-print/Makefile
  head/print/cups-filters/Makefile
  head/print/cups-filters/files/cups_browsed.in
  head/print/cups-filters/files/patch-cupsfilters_colormanager.c
  head/print/cups-filters/files/patch-filter_pdftops.c
  head/print/cups-filters/pkg-descr
  head/print/cups-filters/pkg-plist
  head/print/cups-fxlinuxprint/Makefile
  head/print/cups-fxlinuxprint/files/patch-Makefile.in
  head/print/cups-fxlinuxprint/pkg-plist
  head/print/cups-image/
  head/print/cups-pdf/Makefile
  head/print/cups-pk-helper/Makefile
  head/print/cups-pstoraster/
  head/print/cups-smb-backend/Makefile
  head/print/dymo-cups-drivers/Makefile
  head/print/epson-inkjet-printer-escpr/Makefile
  head/print/foo2zjs/Makefile
  head/print/foomatic-db/Makefile
  head/print/foomatic-db-engine/Makefile
  head/print/foomatic-db-engine/distinfo
  head/print/foomatic-filters/Makefile
  head/print/foomatic-filters/files/patch-Makefile.am
  head/print/foomatic-filters/files/patch-configure.ac
  head/print/foomatic-filters/pkg-plist
  head/print/ghostscript8-base/Makefile
  head/print/ghostscript8-base/files/Makefile.drivers_post
  head/print/ghostscript9-agpl-base/Makefile
  head/print/ghostscript9-agpl-base/files/Makefile.drivers_post
  head/print/ghostscript9-base/Makefile
  head/print/ghostscript9-base/files/Makefile.drivers_post
  head/print/gtklp/Makefile
  head/print/gutenprint-base/Makefile
  head/print/hpijs/Makefile
  head/print/hplip/Makefile
  head/print/hplip/distinfo
  head/print/hplip/files/patch-Makefile.in
  head/print/hplip/files/patch-base__pexpect.py
  head/print/hplip/files/patch-hplip-plugin
  head/print/hplip/files/patch-installer__core_install.py
  head/print/hplip/files/patch-io-hpmud-musb.c
  head/print/hplip/files/patch-prnt__hpcups__ErnieFilter.cpp
  head/print/hplip/files/patch-protocol-discovery-mdns.c
  head/print/hplip/files/pkg-message.in
  head/print/hplip/pkg-plist
  head/print/hplip-plugin/Makefile
  head/print/hplip-plugin/distinfo
  head/print/hplip-plugin/files/patch-installPlugin.py
  head/print/hplip-plugin/files/patch-plugin_install.py
  head/print/hplip-plugin/pkg-plist
  head/print/kde4-print-manager/Makefile
  head/print/libgnomecups/Makefile
  head/print/linux-c6-cups-libs/Makefile
  head/print/linux-f10-cups-libs/Makefile
  head/print/muttprint/Makefile
  head/print/openprinting/Makefile
  head/print/p5-Net-CUPS/Makefile
  head/print/photoprint/Makefile
  head/print/py-pycups/Makefile
  head/print/qpdf/Makefile
  head/print/qpdf/files/patch-libqpdf.pc.in
  head/print/qpdfview/Makefile
  head/print/qt5-printsupport/Makefile
  head/print/scribus/Makefile
  head/print/splix/Makefile
  head/print/system-config-printer/Makefile
  head/print/xfce4-print/Makefile
  head/print/xpp/Makefile
  head/sysutils/cinnamon-control-center/Makefile
  head/sysutils/cinnamon-settings-daemon/Makefile
  head/sysutils/gnome-control-center/Makefile
  head/sysutils/gnome-settings-daemon/Makefile
  head/www/chromium/Makefile
  head/www/opera/Makefile
  head/x11-toolkits/fox14/Makefile
  head/x11-toolkits/gnustep-gui/Makefile
  head/x11-toolkits/gtk20/Makefile
  head/x11-toolkits/gtk30/Makefile
  head/x11-toolkits/qt4-gui/Makefile