12 Commits

Author SHA256 Message Date
10bfb902d4 Accepting request 1320016 from Printing
Remove dependency on update-desktop-files for factory

OBS-URL: https://build.opensuse.org/request/show/1320016
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/hplip?expand=0&rev=166
2025-11-27 14:19:01 +00:00
7ffbbaa882 OBS-URL: https://build.opensuse.org/package/show/Printing/hplip?expand=0&rev=280 2025-11-25 14:01:01 +00:00
ee0405583d - Remove unused BuildRequires: update-desktop-files.
OBS-URL: https://build.opensuse.org/package/show/Printing/hplip?expand=0&rev=279
2025-11-25 13:49:28 +00:00
03fb19a3a4 Rremoved an invisible Unicode U+2002 character in hplip.changes
OBS-URL: https://build.opensuse.org/package/show/Printing/hplip?expand=0&rev=278
2025-11-19 14:29:40 +00:00
f3d2506529 Accepting request 1309931 from Printing
- Move more utilities from hplip-utils to hplip-base.
  * hplip-base now contains all utilities that are not totally useless
    and can run without the Qt GUI.
- Update fix for support of new GPG key, as the key has now been
  uploaded to GPG keyservers (lp#2120738)
  * drop hplip-hardcode-new-signing-key-AC69536A2CF3A243.patch
  * update hplip-change-pgp-server.patch
- Drop dependency on cups-ppdc. It isn't necessary, as PPD
  generation on target system is done by cups-driverd.
- The old and outdated 'hpijs' driver support is finally dropped
  (the 'hpcups' driver is the default driver since 2009)
  so that there is no need for foomatic-filters (boo#1250481)
- Continue refactoring:
  * move GUI tools to "hplip-utils" subpackage
  * convert "hplip" into an empty metapackage that pulls in hplip-utils 
    and all drivers / PPDs (except hpijs PPDs).
- Refactor package structure:
  * hplip: full set of utilities. Pulls in almost all subpackages
    to deliver the "traditional" hplip experience
  * hplip-base: small set of basic utilities that can be run
    without GUI. Includes hp-probe and hp-plugin
  * hplip-cups: minimal package for printing, without PPDs or
    setup helpers
  * hplip-sane: scanning support (unchanged) 
  * hplip-driver-hpcups: hpcups.drv for generating hpcups PPDs on
    the fly (requires ppdc). The functionality of this package is
    similar to the old (misnamed) "hplip-hpijs" package.
  * hplip-driver-hpijs: hpijs.drv for generating PPDs for the deprecated
    hpijs / foomatic_rip filter. Note that this functionality was not part of
    the late hplip-hpijs package, because upstream hasn't ship foomatic PPDs
    since hplip 3.17.11.
  * hplip-ppds-{hpcups,hpps,postscript,hpijs,fax,plugin}: static PPD
    files for different printer types.
    hplip-ppds-hpcups is an alternative to hplip-driver-hpcups.
  * libhplip0: shared library package, used by hplip-cups and
    hplip-sane
  * hplip-common: configuration files and directories used by
    all hplip packages.
- Other spec file changes:
  * Skip deprecated suse_update_desktop_file by default on TW
  * Don't mess with sane configuration in udev rules
  * Only the hpijs packages depend on foomatic-rip, which is only
    provided by cups-filters-1.x. The other packages can be used
    with cups-filters2.
  * Remove Obsoletes: for ancient predecessor packages
  * Remove outdated comments from spec file
  * Shorten package descriptions
  * Fix a couple of rpmlint issues
    
- Fix printer probing using avahi (lp#2120947)
  * Add hplip-fix-driver-probing-using-avahi.patch
  * Add hplip-fix-python-crash-in-avahi.py.patch

OBS-URL: https://build.opensuse.org/request/show/1309931
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/hplip?expand=0&rev=165
2025-10-10 15:07:41 +00:00
756b74b309 OBS-URL: https://build.opensuse.org/package/show/Printing/hplip?expand=0&rev=276 2025-10-09 08:43:31 +00:00
497ec9ee78 - Move more utilities from hplip-utils to hplip-base.
* hplip-base now contains all utilities that are not totally useless
    and can run without the Qt GUI.

- Update fix for support of new GPG key, as the key has now been
  uploaded to GPG keyservers (lp#2120738)
  * drop hplip-hardcode-new-signing-key-AC69536A2CF3A243.patch
  * update hplip-change-pgp-server.patch

- Drop dependency on cups-ppdc. It isn't necessary, as PPD
  generation on target system is done by cups-driverd.

- The old and outdated 'hpijs' driver support is finally dropped
  (the 'hpcups' driver is the default driver since 2009)
  so that there is no need for foomatic-filters (boo#1250481)

- Continue refactoring:
  * move GUI tools to "hplip-utils" subpackage
  * convert "hplip" into an empty metapackage that pulls in hplip-utils 
    and all drivers / PPDs (except hpijs PPDs).

- Refactor package structure:
  * hplip: full set of utilities. Pulls in almost all subpackages
    to deliver the "traditional" hplip experience
  * hplip-base: small set of basic utilities that can be run
    without GUI. Includes hp-probe and hp-plugin
  * hplip-cups: minimal package for printing, without PPDs or
    setup helpers
  * hplip-sane: scanning support (unchanged) 
  * hplip-driver-hpcups: hpcups.drv for generating hpcups PPDs on
    the fly (requires ppdc). The functionality of this package is
    similar to the old (misnamed) "hplip-hpijs" package.
  * hplip-driver-hpijs: hpijs.drv for generating PPDs for the deprecated
    hpijs / foomatic_rip filter. Note that this functionality was not part of
    the late hplip-hpijs package, because upstream hasn't ship foomatic PPDs
    since hplip 3.17.11.
  * hplip-ppds-{hpcups,hpps,postscript,hpijs,fax,plugin}: static PPD
    files for different printer types.
    hplip-ppds-hpcups is an alternative to hplip-driver-hpcups.
  * libhplip0: shared library package, used by hplip-cups and
    hplip-sane
  * hplip-common: configuration files and directories used by
    all hplip packages.
- Other spec file changes:
  * Skip deprecated suse_update_desktop_file by default on TW
  * Don't mess with sane configuration in udev rules
  * Only the hpijs packages depend on foomatic-rip, which is only
    provided by cups-filters-1.x. The other packages can be used
    with cups-filters2.
  * Remove Obsoletes: for ancient predecessor packages
  * Remove outdated comments from spec file
  * Shorten package descriptions
  * Fix a couple of rpmlint issues
    
- Fix printer probing using avahi (lp#2120947)
  * Add hplip-fix-driver-probing-using-avahi.patch
  * Add hplip-fix-python-crash-in-avahi.py.patch

OBS-URL: https://build.opensuse.org/package/show/Printing/hplip?expand=0&rev=275
2025-10-09 08:17:23 +00:00
c3f7a8c460 Accepting request 1300306 from Printing
OBS-URL: https://build.opensuse.org/request/show/1300306
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/hplip?expand=0&rev=164
2025-08-20 11:24:51 +00:00
23d046f249 - Fix verification of HP plugin with new GPG key (lp#2120738)
* add hplip-hardcode-new-signing-key-AC69536A2CF3A243.patch
- Fix python crash in hp-setup on compressed PPD file (lp#2120739)
  * add hp-setup-fix-python-crash-when-manually-importing-gz.patch
- Fix missing urllib.URLopener in python 3.14 (lp#2115046)
  * add hplip-no-urlopener.patch
- Only run cupstestppd if explicitly requested with "--with testppd"
  build parameter

- Updated hplip gpg public key
  fingerprint: 82FF A7C6 AA74 11D9 34BD E173 AC69 536A 2CF3 A243
  https://developers.hp.com/hp-linux-imaging-and-printing/hplipDigitalCertificate.html
- Update to hplip 3.25.6
- Added support for new printers:
  * HP LaserJet Enterprise Flow MFP 8601z
  * HP LaserJet Pro MFP M126a plus
  * HP LaserJet Pro MFP M126nw plus
  * HP LaserJet Pro MFP M126snw plus
  * HP Envy Photo 7200 series
  * HP Envy Photo 7900 series
  * HP OfficeJet Pro 9110 Series
  * HP OfficeJet 9120 Series
  * HP OfficeJet Pro 9120 Series
  * HP OfficeJet Pro 9130 Series

OBS-URL: https://build.opensuse.org/package/show/Printing/hplip?expand=0&rev=273
2025-08-19 14:25:36 +00:00
6af0bcd0d2 Accepting request 1299861 from Printing
- Disable hp-scan-utils on Leap 16.0
  Leap does not want to ship scikit-image -> python-pandas

OBS-URL: https://build.opensuse.org/request/show/1299861
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/hplip?expand=0&rev=163
2025-08-16 18:37:09 +00:00
2685c80bcc Fix syntax of "%bcond_with scan_utils"
OBS-URL: https://build.opensuse.org/package/show/Printing/hplip?expand=0&rev=271
2025-08-15 20:20:18 +00:00
ee64d56499 - Disable hp-scan-utils on Leap 16.0
Leap does not want to ship scikit-image -> python-pandas

OBS-URL: https://build.opensuse.org/package/show/Printing/hplip?expand=0&rev=270
2025-08-15 15:40:10 +00:00
15 changed files with 767 additions and 404 deletions

View File

@@ -2,7 +2,7 @@ Index: b/data/rules/56-hpmud.rules
===================================================================
--- a/data/rules/56-hpmud.rules
+++ b/data/rules/56-hpmud.rules
@@ -1,8 +1,33 @@
@@ -1,8 +1,31 @@
# HPLIP udev rules file. Notify console user if plugin support is required for this device.
+#
+# SUSE changed:
@@ -27,8 +27,6 @@ Index: b/data/rules/56-hpmud.rules
+# is also used to upload firmware into printers that need it
+# see https://bugs.launchpad.net/bugs/1220628
+# a rule that only uploads firmware into printers that need it is added.
+#
+# If possible activate hpaio backend support in /etc/sane.d/dll.conf.
ACTION!="add", GOTO="hpmud_rules_end"
-SUBSYSTEM=="ppdev", OWNER="root", GROUP="lp", MODE="0664"
@@ -37,7 +35,7 @@ Index: b/data/rules/56-hpmud.rules
GOTO="hpmud_rules_end"
LABEL="hpmud_usb_rules"
@@ -13,6 +38,12 @@ ENV{ID_USB_INTERFACES}=="", IMPORT{built
@@ -13,6 +38,9 @@ ENV{ID_USB_INTERFACES}=="", IMPORT{built
ATTR{idVendor}=="03f0", ENV{ID_USB_INTERFACES}=="*:0701??:*|*:ffcc00:", OWNER="root", GROUP="lp", MODE="0664", ENV{libsane_matched}="yes", ENV{hp_test}="yes", ENV{ID_HPLIP}="1"
# This rule will check the smart install feature, plugin status and firmware download for the required printers.
@@ -45,9 +43,6 @@ Index: b/data/rules/56-hpmud.rules
+#ENV{hp_test}=="yes", PROGRAM="/bin/sh -c 'logger -p user.info loading HP Device $env{BUSNUM} $env{DEVNUM}'", RUN+="/bin/sh -c '/usr/bin/nohup /usr/bin/hp-config_usb_printer $env{BUSNUM}:$env{DEVNUM}'"
+# This rule uploads firmware to HP USB printer devices if needed:
+ENV{hp_test}=="yes", PROGRAM="/bin/logger -p user.info udev hpmud.rules runs hp-firmware to test if HP device with USB vendor ID $attr{idVendor} and USB product ID $attr{idProduct} at USB bus ID $env{BUSNUM} and USB device ID $env{DEVNUM} needs firmware and if yes to upload it", RUN+="/usr/bin/hp-firmware -s $env{BUSNUM}:$env{DEVNUM}"
+
+# If possible activate hpaio backend support in /etc/sane.d/dll.conf:
+ENV{libsane_matched}=="yes", RUN+="/bin/sh -c 'if test -w /etc/sane.d/dll.conf ; then sed -i -e /hpaio/d /etc/sane.d/dll.conf ; echo hpaio >>/etc/sane.d/dll.conf ; fi'"
LABEL="hpmud_rules_end"
+

View File

@@ -0,0 +1,28 @@
From 216b15eb68bd5cacd26ff554e244fc4ea50a1acf Mon Sep 17 00:00:00 2001
From: Martin Wilck <mwilck@suse.com>
Date: Fri, 15 Aug 2025 23:10:44 +0200
Subject: [PATCH 1/2] hp-setup: fix python crash when manually importing
gzipped PPD
data read from gzip.GzipFile must be converted to a string, otherwise
the subsequent regex match will cause a python stacktrace.
---
setup.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/setup.py b/setup.py
index 2608f95..962909b 100755
--- a/setup.py
+++ b/setup.py
@@ -552,7 +552,7 @@ else: # INTERACTIVE_MODE
if os.path.exists(file_path) and os.path.isfile(file_path):
if file_path.endswith('.gz'):
- nickname = gzip.GzipFile(file_path, 'r').read(4096)
+ nickname = gzip.GzipFile(file_path, 'r').read(4096).decode("utf-8")
else:
nickname = open(file_path, 'r').read(4096)
--
2.50.1

View File

@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:fb60642e55839c311ee8037bfc739ffc7c77555c176beef5bdbc4f965e322b61
size 682

View File

@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:e872ff28eb2517705a95f6e1839efa1e50a77a33aae8905278df2bd820919653
size 30371001

View File

@@ -1,6 +0,0 @@
-----BEGIN PGP SIGNATURE-----
iF0EABECAB0WIQRKui9m29WpWJSRDgZz13DNpZBHuQUCZ8BY1gAKCRBz13DNpZBH
uS2IAKCA8szJDmNmB9LOn9gqvQtZNKLZGwCgnWs/NEryaAJrtevXQxRtmBn+VeA=
=dcBZ
-----END PGP SIGNATURE-----

BIN
hplip-3.25.6.tar.gz LFS Normal file

Binary file not shown.

11
hplip-3.25.6.tar.gz.asc Normal file
View File

@@ -0,0 +1,11 @@
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2
iQEcBAABCAAGBQJoekszAAoJEF5OTSSjTs1XCjUH/3W/RawreKnt4IuIqUqHMTJn
haeiPj/jdArhbxreCjvYk3Z91VXJ4n2pyVWAwhW8ZKmSzdubDOEUrSs1fiRLF1qe
y/wmCSmDF+ZcQu7/QfLDhZQI7I7IOFKNGTNNlWh1z3HpnHqBywPusM8ej8EgEb76
6tGLlNuo8ykFDAQNJAPCN/qexj/LUs+p/s4lhpkNa+A7OIhBmQkfwscHXXrhf67f
slavMnkCKbccegOtd9+i2NggtwkJDeNqZfgq6J7yXSxAm8jJjdAgJkqLmc9Vkxku
GuUkQffIlHeDKj6jKg8Og+oAeRShLf6rxlFIB/PedJ9bjbZwUZDHUd80dHlAFWU=
=VrP+
-----END PGP SIGNATURE-----

View File

@@ -7,7 +7,7 @@ Index: hplip-3.19.6/base/validation.py
class GPG_Verification(DigiSign_Verification):
- def __init__(self, pgp_site = 'pgp.mit.edu', key = 0x4ABA2F66DBD5A95894910E0673D770CDA59047B9):
+ def __init__(self, pgp_site = 'pgp.surf.nl', key = 0x4ABA2F66DBD5A95894910E0673D770CDA59047B9):
+ def __init__(self, pgp_site = 'keyserver.ubuntu.com', key = 0x82FFA7C6AA7411D934BDE173AC69536A2CF3A243):
self.__pgp_site = pgp_site
self.__key = key
self.__gpg = utils.which('gpg',True)

View File

@@ -0,0 +1,62 @@
From d68d0748c4493ef3192e4f59756ece2bd2fbb004 Mon Sep 17 00:00:00 2001
From: Martin Wilck <mwilck@suse.com>
Date: Tue, 19 Aug 2025 12:06:17 +0200
Subject: [PATCH] hplip: fix driver probing using avahi
- _printer._tcp doesn't work for my printer (HP Smart Tank 7300 series).
mdns.py uses _pdl-datastream._tcp, which works.
- my printer sends `usb_MDL` property, which mdns.py accepts as alternative
for `ty`.
- "bonjour" search protocol exists nowhere else in the code. "avahi" does.
---
base/avahi.py | 8 ++++++--
probe.py | 4 ++--
2 files changed, 8 insertions(+), 4 deletions(-)
diff --git a/base/avahi.py b/base/avahi.py
index 51795dd..b82a089 100755
--- a/base/avahi.py
+++ b/base/avahi.py
@@ -37,6 +37,9 @@ def detectNetworkDevices(ttl=4, timeout=10):
# Obtain all the resolved services which has service type '_printer._tcp' from avahi-browse
p = Popen(['avahi-browse', '-kprt', '_printer._tcp'], stdout=PIPE)
output = to_string_utf8(p.communicate()[0])
+ p = Popen(['avahi-browse', '-kprt', '_pdl-datastream._tcp'], stdout=PIPE)
+ output += to_string_utf8(p.communicate()[0])
+
for line in output.splitlines():
if line.startswith('='):
bits = line.split(';')
@@ -55,11 +58,12 @@ def detectNetworkDevices(ttl=4, timeout=10):
details = bits[9].split('" "')
for item in details:
key, value = item.split('=', 1)
- if key == 'ty':
+ if key == 'ty' or key == 'usb_MDL':
y['mdns'] = value
y['device1'] = "MFG:Hewlett-Packard;MDL:%s;CLS:PRINTER;" % value
break
- found_devices[y['ip']] = y
+ if y['ip'] not in found_devices:
+ found_devices[y['ip']] = y
#log.debug("ip=%s hn=%s ty=%s" %(ip,y['hn'], y['mdns']))
except socket.gaierror:
pass
diff --git a/probe.py b/probe.py
index 82e5de9..3bf3ba8 100755
--- a/probe.py
+++ b/probe.py
@@ -93,8 +93,8 @@ try:
elif o in ('-m', '--method'):
method = a.lower().strip()
- if method not in ('slp', 'mdns', 'bonjour'):
- mod.usage(error_msg=["Invalid network search protocol name. Must be 'slp' or 'mdns'."])
+ if method not in ('slp', 'mdns', 'avahi'):
+ mod.usage(error_msg=["Invalid network search protocol name. Must be 'slp', 'mdns', or 'avahi'."])
else:
bus = ['net']
--
2.50.1

View File

@@ -0,0 +1,28 @@
From 5bdb75b1b3397abd58a69aba18c6aacf8d70df77 Mon Sep 17 00:00:00 2001
From: Martin Wilck <mwilck@suse.com>
Date: Tue, 19 Aug 2025 23:38:24 +0200
Subject: [PATCH] hplip: fix python crash in avahi.py
The avahi search method may crash on MDNS records that have
an empty "details" field (field 9). This can happen e.g. for
existing shared local printers advertized by cups.
---
base/avahi.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/base/avahi.py b/base/avahi.py
index b82a089..f168585 100755
--- a/base/avahi.py
+++ b/base/avahi.py
@@ -43,7 +43,7 @@ def detectNetworkDevices(ttl=4, timeout=10):
for line in output.splitlines():
if line.startswith('='):
bits = line.split(';')
- if bits[2] == 'IPv4' and len(bits[7].split('.')) == 4:
+ if bits[2] == 'IPv4' and len(bits[7].split('.')) == 4 and bits[9] != "":
ip = bits[7]
port = bits[8]
# Run through the offered addresses and see if we have a bound local
--
2.50.1

79
hplip-no-urlopener.patch Normal file
View File

@@ -0,0 +1,79 @@
diff --git a/base/device.py b/base/device.py
index 2fdb29c..ca0d97e 100644
--- a/base/device.py
+++ b/base/device.py
@@ -2526,9 +2526,9 @@ Content-length: %d\r
data = None
log.debug("Opening: %s" % url2)
- opener = LocalOpener({})
+ opener = LocalOpener()
try:
- f = opener.open(url2, data)
+ f = opener.open_hp(url2, data)
except Error:
log.error("Status read failed: %s" % url2)
@@ -2548,7 +2548,7 @@ Content-length: %d\r
try:
url2 = "%s&loc=%s" % (self.device_uri.replace('hpfax:', 'hp:'), url)
data = self
- opener = LocalOpenerEWS_LEDM({})
+ opener = LocalOpenerEWS_LEDM()
try:
if footer:
return opener.open_hp(url2, data, footer)
@@ -2563,7 +2563,7 @@ Content-length: %d\r
try:
url2 = "%s&loc=%s" % (self.device_uri.replace('hpfax:', 'hp:'), url)
data = self
- opener = LocalOpener_LEDM({})
+ opener = LocalOpener_LEDM()
try:
if footer:
return opener.open_hp(url2, data, footer)
@@ -2580,7 +2580,7 @@ Content-length: %d\r
url="/cdm/supply/v1/suppliesPublic"
url2 = "%s&loc=%s" % (self.device_uri.replace('hpfax:', 'hp:'), url)
data = self
- opener = LocalOpener_CDM({})
+ opener = LocalOpener_CDM()
try:
if footer:
return opener.open_hp(url2, data, footer)
@@ -2688,7 +2688,7 @@ Content-length: %d\r
# URLs: hp:/usb/HP_LaserJet_3050?serial=00XXXXXXXXXX&loc=/hp/device/info_device_status.xml
-class LocalOpener(urllib_request.URLopener):
+class LocalOpener():
def open_hp(self, url, dev):
log.debug("open_hp(%s)" % url)
@@ -2718,7 +2718,7 @@ class LocalOpener(urllib_request.URLopener):
return response#.fp
# URLs: hp:/usb/HP_OfficeJet_7500?serial=00XXXXXXXXXX&loc=/hp/device/info_device_status.xml
-class LocalOpenerEWS_LEDM(urllib_request.URLopener):
+class LocalOpenerEWS_LEDM():
def open_hp(self, url, dev, foot=""):
log.debug("open_hp(%s)" % url)
@@ -2744,7 +2744,7 @@ class LocalOpenerEWS_LEDM(urllib_request.URLopener):
# URLs: hp:/usb/HP_OfficeJet_7500?serial=00XXXXXXXXXX&loc=/hp/device/info_device_status.xml
-class LocalOpener_LEDM(urllib_request.URLopener):
+class LocalOpener_LEDM():
def open_hp(self, url, dev, foot=""):
log.debug("open_hp(%s)" % url)
@@ -2771,7 +2771,7 @@ class LocalOpener_LEDM(urllib_request.URLopener):
# URLs: hp:/usb/HP_OfficeJet_7500?serial=00XXXXXXXXXX&loc=/hp/device/info_device_status.xml
-class LocalOpener_CDM(urllib_request.URLopener):
+class LocalOpener_CDM():
def open_hp(self, url, dev, foot=""):
log.debug("open_hp(%s)" % url)
match_obj = http_pat_url.search(url)

View File

@@ -2,8 +2,5 @@ from Config import *
addFilter("arch-dependent-file-in-usr-share")
# Ignore any duplicate files
addFilter("files-duplicate .*/hplip/.*/__init__.py")
addFilter("files-duplicate .*/hplip/*/__init__.*pyc")
addFilter("files-duplicate .*/hplip/.*/__pycache__/__init__.*.pyc")
#
addFilter("files-duplicate .*/hplip/.*/__init__.py")
addFilter("non-executable-script /usr/share/hplip/.*")

View File

@@ -1,3 +1,123 @@
-------------------------------------------------------------------
Sat Nov 22 21:18:02 CET 2025 - Stanislav Brabec <sbrabec@suse.com>
- Remove unused BuildRequires: update-desktop-files.
-------------------------------------------------------------------
Wed Oct 8 20:43:58 UTC 2025 - Martin Wilck <mwilck@suse.com>
- Move more utilities from hplip-utils to hplip-base.
* hplip-base now contains all utilities that are not totally useless
and can run without the Qt GUI.
-------------------------------------------------------------------
Wed Oct 8 14:55:02 UTC 2025 - Martin Wilck <mwilck@suse.com>
- Update fix for support of new GPG key, as the key has now been
uploaded to GPG keyservers (lp#2120738)
* drop hplip-hardcode-new-signing-key-AC69536A2CF3A243.patch
* update hplip-change-pgp-server.patch
-------------------------------------------------------------------
Wed Oct 8 14:28:09 UTC 2025 - Martin Wilck <mwilck@suse.com>
- Drop dependency on cups-ppdc. It isn't necessary, as PPD
generation on target system is done by cups-driverd.
-------------------------------------------------------------------
Mon Sep 29 13:13:08 UTC 2025 - Johannes Meixner <jsmeix@suse.com>
- The old and outdated 'hpijs' driver support is finally dropped
(the 'hpcups' driver is the default driver since 2009)
so that there is no need for foomatic-filters (boo#1250481)
-------------------------------------------------------------------
Thu Aug 21 10:50:17 UTC 2025 - Martin Wilck <martin.wilck@suse.com>
- Continue refactoring:
* move GUI tools to "hplip-utils" subpackage
* convert "hplip" into an empty metapackage that pulls in hplip-utils
and all drivers / PPDs (except hpijs PPDs).
-------------------------------------------------------------------
Tue Aug 19 13:33:02 UTC 2025 - Martin Wilck <mwilck@suse.com>
- Refactor package structure:
* hplip: full set of utilities. Pulls in almost all subpackages
to deliver the "traditional" hplip experience
* hplip-base: small set of basic utilities that can be run
without GUI. Includes hp-probe and hp-plugin
* hplip-cups: minimal package for printing, without PPDs or
setup helpers
* hplip-sane: scanning support (unchanged)
* hplip-driver-hpcups: hpcups.drv for generating hpcups PPDs on
the fly (requires ppdc). The functionality of this package is
similar to the old (misnamed) "hplip-hpijs" package.
* hplip-driver-hpijs: hpijs.drv for generating PPDs for the deprecated
hpijs / foomatic_rip filter. Note that this functionality was not part of
the late hplip-hpijs package, because upstream hasn't ship foomatic PPDs
since hplip 3.17.11.
* hplip-ppds-{hpcups,hpps,postscript,hpijs,fax,plugin}: static PPD
files for different printer types.
hplip-ppds-hpcups is an alternative to hplip-driver-hpcups.
* libhplip0: shared library package, used by hplip-cups and
hplip-sane
* hplip-common: configuration files and directories used by
all hplip packages.
- Other spec file changes:
* Skip deprecated suse_update_desktop_file by default on TW
* Don't mess with sane configuration in udev rules
* Only the hpijs packages depend on foomatic-rip, which is only
provided by cups-filters-1.x. The other packages can be used
with cups-filters2.
* Remove Obsoletes: for ancient predecessor packages
* Remove outdated comments from spec file
* Shorten package descriptions
* Fix a couple of rpmlint issues
- Fix printer probing using avahi (lp#2120947)
* Add hplip-fix-driver-probing-using-avahi.patch
* Add hplip-fix-python-crash-in-avahi.py.patch
-------------------------------------------------------------------
Fri Aug 15 21:38:25 UTC 2025 - Martin Wilck <mwilck@suse.com>
- Fix verification of HP plugin with new GPG key (lp#2120738)
* add hplip-hardcode-new-signing-key-AC69536A2CF3A243.patch
- Fix python crash in hp-setup on compressed PPD file (lp#2120739)
* add hp-setup-fix-python-crash-when-manually-importing-gz.patch
- Fix missing urllib.URLopener in python 3.14 (lp#2115046)
* add hplip-no-urlopener.patch
- Only run cupstestppd if explicitly requested with "--with testppd"
build parameter
-------------------------------------------------------------------
Fri Aug 15 15:59:19 UTC 2025 - Martin Wilck <mwilck@suse.com>
- Updated hplip gpg public key
fingerprint: 82FF A7C6 AA74 11D9 34BD E173 AC69 536A 2CF3 A243
https://developers.hp.com/hp-linux-imaging-and-printing/hplipDigitalCertificate.html
- Update to hplip 3.25.6
- Added support for new printers:
* HP LaserJet Enterprise Flow MFP 8601z
* HP LaserJet Pro MFP M126a plus
* HP LaserJet Pro MFP M126nw plus
* HP LaserJet Pro MFP M126snw plus
* HP Envy Photo 7200 series
* HP Envy Photo 7900 series
* HP OfficeJet Pro 9110 Series
* HP OfficeJet 9120 Series
* HP OfficeJet Pro 9120 Series
* HP OfficeJet Pro 9130 Series
-------------------------------------------------------------------
Thu Aug 14 19:57:37 UTC 2025 - Lubos Kocman <lubos.kocman@suse.com>
- Disable hp-scan-utils on Leap 16.0
Leap does not want to ship scikit-image -> python-pandas
-------------------------------------------------------------------
Tue Jul 15 17:52:47 UTC 2025 - Martin Wilck <mwilck@suse.com>
@@ -122,7 +242,7 @@ Wed Jan 3 16:11:11 UTC 2024 - Martin Wilck <mwilck@suse.com>
* HP OfficeJet Pro 9110b series
* HP Color LaserJet Enterprise Flow MFP X58045z
* HP Color LaserJet Enterprise Flow MFP X58045zs
* HP Color LaserJet Enterprise MFP X58045dn
* HP Color LaserJet Enterprise MFP X58045dn
* HP Color LaserJet Enterprise MFP X58045
* HP LaserJet Pro P1106 plus
* HP LaserJet Pro P1108 plus

View File

@@ -1,39 +1,37 @@
-----BEGIN PGP PUBLIC KEY BLOCK-----
Version: GnuPG v2.0.18 (GNU/Linux)
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
=lgaV
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
6saq
=EWRb
-----END PGP PUBLIC KEY BLOCK-----

View File

@@ -1,7 +1,7 @@
#
# spec file for package hplip
#
# Copyright (c) 2025 SUSE LLC
# Copyright (c) 2025 SUSE LLC and contributors
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -16,6 +16,8 @@
#
%global basic_tools align clean colorcal diagnose_queues doctor fab firmware info levels logcapture makecopies makeuri plugin probe query sendfax setup testpage timedate unload
# python-rpm-macros doesn't work for hplip!
%if 0%{?suse_version} >= 1500
%define pyversion 3
@@ -36,6 +38,21 @@
%global make_install make DESTDIR=%{buildroot} V=1 install
%endif
%if 0%{?suse_version} == 1600 && 0%{?is_opensuse}
# Build without scanning support
%bcond_with scan_utils
%else
# Build scanning support
%bcond_without scan_utils
%endif
# update_desktop_files is deprecated in TW
%if 0%{?suse_version} > 1600
%bcond_with update_desktop
%else
%bcond_without update_desktop
%endif
%if 0%{use_qt5}
%global config_qt_opts --disable-qt4 --enable-qt5
%global requires_qt %{pymod qt5}
@@ -46,8 +63,10 @@
%global ui_dir ui4
%endif
%global drvdir %{_datadir}/cups/drv
Name: hplip
Version: 3.25.2
Version: 3.25.6
Release: 0
Summary: HP's Printing, Scanning, and Faxing Software
License: BSD-3-Clause AND GPL-2.0-or-later AND MIT
@@ -66,8 +85,6 @@ Source2: hplip.keyring
# Patch0...Patch9 is for patches from HP:
# Patch10...Patch99 is for Suse patches for the sources from HP:
# Source100... is for special SUSE sources:
# Source102 is a small man page for /usr/bin/hpijs:
Source102: hpijs.1.gz
# Actual drivers for hplip-missing-drivers.patch
Source103: hp-laserjet_cp_1025nw.ppd.gz
Source104: hp-laserjet_professional_p_1102w.ppd.gz
@@ -119,12 +136,21 @@ Patch604: hplip-sclpml-strcasestr.patch
Patch605: hplip-hpaio-gcc14.patch
Patch606: hplip-base-fix-error-in-ConfigBase-handling.patch
Patch607: hplip-utils-Fix-plugin-verification-with-sha256.patch
# lp#2120739
Patch608: hp-setup-fix-python-crash-when-manually-importing-gz.patch
# lp#2115046
Patch610: hplip-no-urlopener.patch
Patch611: hplip-fix-driver-probing-using-avahi.patch
Patch612: hplip-fix-python-crash-in-avahi.py.patch
# PATCH-FIX-UPSTREAM https://bugs.launchpad.net/hplip/+bug/2096650
Patch651: hplip-3.24.4-gcc15.patch
# Compatibility patches for old SUSE releases
Patch700: hplip-base-replace-f-string-with-string.format-for-p.patch
Patch701: hpcups-fix-compilation-on-SLE12.patch
# cups-rpm-helper is now pulled in indirectly via cups-devel.
# This causes the "postscriptdriver" provides to be generated.
# To avoid that, put "Ignore: cups-devel: cups-rpm-helper in the prjconf.
%if %use_qt5
BuildRequires: %{pymod qt5-devel}
%else
@@ -151,7 +177,9 @@ BuildRequires: python-rpm-macros
BuildRequires: readline-devel
BuildRequires: sane-backends-devel
BuildRequires: systemd-rpm-macros
%if %{with update_desktop}
BuildRequires: update-desktop-files
%endif
#!BuildIgnore: clang8
#!BuildIgnore: libclang8
# Break this dependency chain that has caused build breakage
@@ -161,154 +189,235 @@ BuildRequires: update-desktop-files
# Break this dependency chain that has caused build breakage
# python3-qt5-devel -> libqt5-qtwebengine-devel -> libavcodec58 -> libdav1d.so.1
#!BuildIgnore: libqt5-qtwebengine-devel
# Require the exact matching version-release of the hpijs sub-package to make sure
# to have the exact matching version of libhpip and libhpmud installed.
# The exact matching version-release of the sub-package is available on the same
# repository where the main-package is (compare the "Recommends: hplip" entry below).
Requires: %{name}-hpijs = %{version}-%{release}
# Require the exact matching version-release of the sane sub-package to make sure
# to have the exact matching version of libsane-hpaio installed:
Requires: %{name}-sane = %{version}-%{release}
Requires: %{pymod dbus-python} >= 0.80
Requires: %{pymod gobject}
Requires: %{requires_qt}
Requires: cups > 1.5
# foomatic-filters and cups-filters-foomatic-rip
# do not require Ghostscript because depending on the PPD
# (e.g. some PPDs for PostScript printers in OpenPrintingPPDs-postscript)
# foomatic-rip can also be used without Ghostscript but for the drivers
# HPIJS and HPCUPS Ghostscript is needed.
# The RPM requirement for ghostscript should actually be in the
# hplip-hpijs sub-package but this would bloat a minimalist system
# (see the comment for the hplip-hpijs sub-package below).
# Therefore the hplip main package which is intended
# to get "all the HPLIP stuff" installed has the RPM requirement:
# Because foomatic-rip-hplip has CVE-2011-2697 (bnc#698451)
# plus a leftover in CVE-2004-0801 (bnc#59233)
# foomatic-rip-hplip is no longer installed and foomatic-rip
# from foomatic-filters or cups-filters-foomatic-rip is used instead.
# The RPM requirement for foomatic-filters should actually be
# in the hplip-hpijs sub-package but this would bloat a minimalist system
# (see the comment for the hplip-hpijs sub-package below).
# Therefore the hplip main package which is intended
# to get "all the HPLIP stuff" installed has the RPM requirement:
Requires: foomatic-filters
Requires: ghostscript
# hp-plugin requries lsb_release
Requires: lsb-release
Requires(post): %{_bindir}/find
Requires(post): /bin/grep
Requires(post): /bin/sed
Requires(post): coreutils
# Require the exact matching version-release of the utils subackage.
Requires: %{name}-utils = %{version}-%{release}
# To ensure the "hplip" package provides a similar user experience as before,
# pull in the necessary PPDs.
%if 0%{?suse_version} >= 1500
Recommends: python3-reportlab
# Works with either driver-hpcus or ppds-hpcups; driver-hpcups is preferred
Requires: (%{name}-driver-hpcups or %{name}-ppds-hpcups)
Suggests: %{name}-driver-hpcups
%else
# On older distros, prefer ppds for historical reasons
Requires: %{name}-ppds-hpcups
%endif
# Obsolete earlier package names
Obsoletes: hplip17
Provides: hplip3 = 3.9.5
Obsoletes: hplip3 < 3.9.5
# cups-rpm-helper is now pulled in indirectly via cups-devel.
# This causes the "postscriptdriver" provides to be generated.
# To avoid that, put "Ignore: cups-devel: cups-rpm-helper in the prjconf.
Requires: %{name}-ppds-fax = %{version}-%{release}
Requires: %{name}-ppds-hpps = %{version}-%{release}
Requires: %{name}-ppds-postscript = %{version}-%{release}
# hplip3 and hplip3-hpijs existed only in SLE11 as an alternative in addition to hplip:
Obsoletes: hplip3
Obsoletes: hplip3-hpijs
%description
The Hewlett-Packard Linux Imaging and Printing project (HPLIP) provides
a unified single and multifunction connectivity solution for HP
printers, scanners, and all-in-one devices.
support for HP printers, scanners, and all-in-one devices.
This package contains command line and UI front-ends for HPLIP, and tools
for extra functionality such as status and supply information. It is
not required for basic printing and scanning with HP hardware, except
for those devices that need the proprietary hplip plugin, see
https://developers.hp.com/hp-linux-imaging-and-printing/binary_plugin.html
This is a meta package that pulls in the entire HPLIP software suite.
%package hpijs
Summary: Printer drivers for HP printers and all-in-one devices
# On a minimalist system only hplip-hpijs may be installed
# or on a minimalist package repository (e.g. on the openSUSE CDs)
# only hplip-hpijs may be available (even when a usual system is installed).
# When only hplip-hpijs is there, it should tell the dependency resolver
# that for usual functionality, hplip should be installed too (if possible).
# Unfortunately the installer ignores suggested packages silently
# but on the other hand I cannot use "Recommends hplip" here
# because the installer installs recommended packages silently
# which would bloat a minimal selection (when hplip is available to be installed)
# because the minimal selection contains hplip-hpijs which recommends hplip
# so that the installer installs hplip and all what this requires silently
# see https://bugzilla.novell.com/show_bug.cgi?id=546893
# Require only the matching version of the hplip main-package
# (compare the "Requires: hplip-hpijs" entry above) but do not depend
# on the exact matching release because the exact matching release
# may be not available to be installed (e.g. when hplip-hpijs-1.2.3-4.5 is
# installed from the openSUSE CDs but on our official online repository
# only hplip-1.2.3-6.7 is available which should usually also work):
%package utils
Summary: HPLIP GUI utilities
Group: Hardware/Printing
Requires: %{name}-udev-rules = %{version}-%{release}
Requires: %{name}-base = %{version}-%{release}
Requires: %{pymod dbus-python} >= 0.80
Requires: %{pymod gobject}
Requires: %{requires_qt}
%if 0%{?suse_version} >= 1500
Recommends: python3-reportlab
%endif
# Make sure we obsolete old scan-utils
# in case we're built without scan_utils
%if %{without scan_utils}
Obsoletes: hplip-scan-utils < %{version}
%endif
%description utils
The Hewlett-Packard Linux Imaging and Printing project (HPLIP) provides
support for HP printers, scanners, and all-in-one devices.
This package contains graphical and command line utilities with extended
functionality, specifically "hp-toolbox". It is not necessary for printing
and scanning with HP devices.
For setting up new devices, install hplip-driver-* or hplip-ppds-* packages.
%package base
Summary: HPLIP basic utilities
Group: Hardware/Printing
Requires: %{name}-cups = %{version}-%{release}
Requires: %{name}-sane = %{version}-%{release}
# hp-plugin installation fails without /etc/sane/dll.conf
Requires: sane-backends
Requires: wget
%description base
The Hewlett-Packard Linux Imaging and Printing project (HPLIP) provides
support for HP printers, scanners, and all-in-one devices.
This package contains basic command line utilities for probing HP printers
and all-in-one devices, and for installing the proprietary HP plugin.
For setting up new devices, install hplip-driver-* or hp-ppds-* packages.
%package common
Summary: HPLIP common files
Group: Hardware/Printing
BuildArch: noarch
Provides: %{name}-udev-rules = %{version}-%{release}
Obsoletes: %{name}-udev-rules < %{version}-%{release}
%description common
This package contains common files needed by other hplip packages.
%package -n libhplip0
Summary: Shared libraries for the HPLIP printing system
Group: System/Libraries
# rpmlint complains about a versioned dependency here
Requires: %{name}-common
%description -n libhplip0
This package contains shared libraries needed by other hplip packages.
%package cups
Summary: HPLIP printing backends and filters for CUPS
Group: Hardware/Printing
# Require the exact matching version-release of the libhpli0 sub-package.
Requires: %{name}-common = %{version}-%{release}
Requires: cups > 1.5
Requires: libhplip0 = %{version}-%{release}
%if 0%{?suse_version} >= 1500
# Works with either driver-hpcus or ppds-hpcups; driver-hpcups is preferred
Recommends: (%{name}-driver-hpcups or %{name}-ppds-hpcups)
Suggests: %{name}-driver-hpcups
Supplements: (%{name}-common and cups)
%else
# On older distros, prefer ppds for historical reasons
Recommends: %{name}-ppds-hpcups
%endif
# cups-filters can be provided by the cups-filters2 package
Recommends: cups-filters
Recommends: %{name}-base = %{version}
Recommends: ghostscript
Suggests: %{name} = %{version}
# Since Nov 14 2007 ghostscript-library does no longer require /usr/bin/hpijs
# but only "Suggests hplip-hpijs" (see Novell/Suse Bugzilla bnc#341564).
# Have the matching "reverse suggests" = "Enhances" here
# to document the ghostscript <-> hplip-hpijs relationship:
Enhances: ghostscript
# hpijs-standalone was a stand-alone minimalist package
# which is no longer provided since a long time.
# hplip-hpijs and hpijs-standalone both contain /usr/bin/hpijs
# so that both packages have a RPM conflict which should
# be solved by a silent replacement of the old hpijs-standalone.
# This Obsoletes is intentionally unversioned because
# hplip-hpijs should replace any version of hpijs-standalone.
Obsoletes: hpijs-standalone
# Either the hplip17 packages or the hplip packages can be installed,
# see https://bugzilla.novell.com/show_bug.cgi?id=251830#c20
# for the full story why there is this unversioned Obsoletes:
Obsoletes: hplip17-hpijs
# Obsolete the hplip3 copy that was introduced for older SLED11-GA HP preloads:
Provides: hplip3-hpijs = 3.9.5
Obsoletes: hplip3-hpijs < 3.9.5
# PackMan provides HPLIP in the packages hplip and hplip-hpcups.
# HPLIP does not work if the openSUSE packages hplip and hplip-hpijs
# are installed together with a leftover PackMan package hplip-hpcups
# see https://bugzilla.novell.com/show_bug.cgi?id=515005#c17
# This Obsoletes is intentionally unversioned because
# the openSUSE package hplip-hpijs must replace
# any version of PackMan's hplip-hpcups package.
Obsoletes: hplip-hpcups
Suggests: %{name}-ppds-hpps = %{version}
Suggests: %{name}-ppds-postscript = %{version}
Suggests: %{name}-ppds-fax = %{version}
%description hpijs
This package contains the backend drivers and PPDs for printing
with HP printers using CUPS.
%description cups
This package contains filter programs and backends for the CUPS printing
system which are necessary for printing with HP printers.
HPCUPS is HPLIP's native CUPS printer driver for HP printers.
HPIJS (deprecated) is HPLIP's Ghostscript printer driver for
HP printers, and only used for some Fax devices nowadays.
%package driver-hpcups
Summary: Driver for HP printers and all-in-one devices (hpcups)
Group: Hardware/Printing
BuildArch: noarch
Requires: %{name}-cups = %{version}-%{release}
Conflicts: %{name}-ppds-hpcups
# Until October 2025, the package with the misleading name "hplip-hpijs"
# provided the hpcups driver and PPDs
Provides: %{name}-hpijs = %{version}-%{release}
Obsoletes: %{name}-hpijs < %{version}-%{release}
Install the "hplip" package if you need the proprietary HP plugin
required by some devices, or additional functionality besides plain
printing.
%description driver-hpcups
This package provides printer setup support for most HP printers and all-in-one
devices. It uses CUPS functionality to generate the PPDs for the printers
dynamically.
This package is not necessary for operation of already configured devices.
%package ppds-hpcups
Summary: PPDs for HP printers and all-in-one devices (hpcups)
Group: Hardware/Printing
BuildArch: noarch
Requires: %{name}-cups = %{version}-%{release}
Conflicts: %{name}-driver-hpcups
# Until October 2025, the package with the misleading name "hplip-hpijs"
# provided the hpcups driver and PPDs
Provides: %{name}-hpijs = %{version}-%{release}
Obsoletes: %{name}-hpijs < %{version}-%{release}
%description ppds-hpcups
This package provides printer setup support for most HP printers and all-in-one
devices. It contains statically compiled PPDs.
This package is not necessary for operation of already configured devices.
%package ppds-postscript
Summary: PPDs for HP printers (PostScript)
Group: Hardware/Printing
BuildArch: noarch
# Also PostScript printers may benefit from HP's special CUPS backend 'hp'
# but normally PostScript printers also work with the generic CUPS backends:
Recommends: %{name}-cups = %{version}-%{release}
%description ppds-postscript
This package provides printer setup support for HP PostScript printers that need no
CUPS filter.
This package is not necessary for operation of already configured devices.
%package ppds-hpps
Summary: PPDs for HP printers (PostScript + hpps)
Group: Hardware/Printing
BuildArch: noarch
Requires: %{name}-cups = %{version}-%{release}
%description ppds-hpps
This package provides printer setup support for HP PostScript printers using the
hpps filter, which adds support for model-specific functionality such as
"Secure printing".
This package is not necessary for operation of already configured devices.
%package ppds-fax
Summary: PPDs for HP Fax devices
Group: Hardware/Printing
BuildArch: noarch
Requires: %{name}-cups = %{version}-%{release}
%description ppds-fax
This package provides support for HP fax devices and multi-function devices.
This package is not necessary for operation of already configured devices.
%package ppds-plugin
Summary: PPDs for HP printers (proprietary plugin)
Group: Hardware/Printing
BuildArch: noarch
Requires: %{name}-cups = %{version}-%{release}
# Require hplip for the hp-plugin tool
Requires: %{name}-base = %{version}-%{release}
%description ppds-plugin
This package provides printer setup support for HP printers that need the
proprietary HPLIP plugin. Use the hp-plugin tool from the %{name}-base package
to install the plugin.
This package is not necessary for operation of already configured devices.
%package sane
Summary: SANE backends for HP scanners and all-in-one devices
# Require the exact matching version-release of the hpijs sub-package to make sure
# to have the exact matching version of libhpip and libhpmud installed.
# A wrong library version may let libsane-hpaio crash (e.g. segfault)
# which lets the whole scanning stack frontend<->libsane-dll<->libsane-backend crash
# also for any other backend when the hpaio backend is enabled (e.g. "scanimage -L"):
Group: Hardware/Scanner
Requires: %{name}-hpijs = %{version}-%{release}
Requires: %{name}-udev-rules = %{version}-%{release}
# See comment in hpijs sub-package for same Suggests:
# Require the exact matching version-release of the libhpli0 sub-package.
Requires: %{name}-common = %{version}-%{release}
Requires: libhplip0 = %{version}-%{release}
Recommends: %{name}-base = %{version}
Suggests: %{name} = %{version}
Enhances: sane-backends
# Automatically install this package if hpijs sub-package and sane-backends are
# both installed (syntax only
# Automatically install this package if hplip-common and sane-backends are
%if 0%{?suse_version} >= 1500
Supplements: (%{name}-hpijs and sane-backends)
Supplements: (%{name}-common and sane-backends)
%endif
%description sane
This package includes the backend driver for scanning with HP scanners
and all-in-one devices using SANE tools like xsane or scanimage.
The Hewlett-Packard Linux Imaging and Printing project (HPLIP) provides
support for HP printers, scanners, and all-in-one devices.
This package provides scanning support for HP scanners and all-in-one
devices. Some devices need the proprietary hplip plugin. Use the hp-plugin
tool from the %{name}-base package to install the plugin.
%if %{with scan_utils}
%package scan-utils
Summary: HPLIP scanning frontends hp-scan and hp-uiscan
# SLE does not provide python-pillow (PIL) (bsc#1131613)
@@ -327,13 +436,7 @@ Obsoletes: %{name}-scan < %{version}-%{release}
This package provides the "hp-scan" and "hp-uiscan" frontend utilities. These
utilities are alternatives to the SANE frontends "xsane" and "scanimage". They
expose some advanced features of certain HP scanner models.
%package udev-rules
Summary: HPLIP udev rules
Group: Hardware/Scanner
%description udev-rules
This package provides the udev rules required to use these devices as a normal user.
%endif
%package devel
Summary: Development files for hplip
@@ -351,7 +454,7 @@ Requires: libusb-1_0-devel
Requires: net-snmp-devel
%description devel
This sub-package is only required by developers.
This package is only required by developers.
%prep
# Be quiet when unpacking:
@@ -391,6 +494,10 @@ This sub-package is only required by developers.
%patch -P 605 -p1
%patch -P 606 -p1
%patch -P 607 -p1
%patch -P 608 -p1
%patch -P 610 -p1
%patch -P 611 -p1
%patch -P 612 -p1
%patch -P 651 -p1
%if 0%{?suse_version} < 1500
# python2 compatibility
@@ -424,22 +531,12 @@ export CXXFLAGS="%{optflags} -fno-strict-aliasing -Wno-error=return-type"
# According to http://hplipopensource.com/hplip-web/release_notes.html
# all drv installs require CUPSDDK 1.2.3 or higher.
# Otherwise a static PPD install must be performed.
# Furthermore dynamic PPDs will be deprecated in the future in CUPS,
# see http://www.cups.org/str.php?L3772
# For hpcups static PPD install one needs:
# --enable-hpcups-install enable hpcups install (default=yes)
# --disable-cups-drv-install enable cups dynamic ppd install (default=yes)
# --enable-cups-ppd-install enable cups static ppd install (default=no)
# For both hpcups and hpijs install with static PPDs one needs additionally:
# --enable-hpijs-install enable hpijs install (default=no)
# --disable-foomatic-drv-install enable foomatic dynamic ppd install (default=no), uses drvdir and hpppddir
# --enable-foomatic-ppd-install enable foomatic static ppd install (default=no), uses hpppddir
# Because foomatic-rip-hplip has CVE-2011-2697 (bnc#698451) plus a leftover in CVE-2004-0801 (bnc#59233)
# which are fixed up to openSUSE 11.4 with patches, after openSUSE 11.4 (i.e. since openSUSE 12.1)
# foomatic-rip-hplip is no longer installed and foomatic-rip from
# foomatic-filters or cups-filters-foomatic-rip is used instead so that
# --disable-foomatic-rip-hplip-install is explicitly set and as a consequence the "cupsFilter" entries
# in the static PPDs are changed in the install section to use foomatic-rip.
# foomatic-rip-hplip is no longer installed and because foomatic-rip is a generic security issue
# and only used by 'hpijs' which is dropped via --disable-hpijs-install also foomatic support is dropped
# via --disable-foomatic-drv-install --disable-foomatic-ppd-install --disable-foomatic-rip-hplip-install
# see https://bugzilla.suse.com/show_bug.cgi?id=1250481
# Since HPLIP 3.13.10 --with-htmldir is new but it does not inhertit its value from --with-docdir
# so that --with-htmldir must be explicitly set.
%configure \
@@ -454,17 +551,17 @@ export CXXFLAGS="%{optflags} -fno-strict-aliasing -Wno-error=return-type"
--enable-fax-build \
--enable-dbus-build \
--enable-hpcups-install \
--disable-cups-drv-install \
--enable-cups-ppd-install \
--enable-hpijs-install \
--disable-foomatic-drv-install \
--enable-cups-drv-install \
--disable-cups-ppd-install \
--disable-hpijs-install \
--disable-imageProcessor-build \
--enable-foomatic-ppd-install \
--disable-foomatic-drv-install \
--disable-foomatic-ppd-install \
--disable-foomatic-rip-hplip-install \
--with-hpppddir=%{_datadir}/cups/model/manufacturer-PPDs/%{name} \
--with-cupsbackenddir=%{_prefix}/lib/cups/backend \
--with-cupsfilterdir=%{_prefix}/lib/cups/filter \
--with-drvdir=%{_prefix}/lib/cups/driver \
--with-drvdir=%{drvdir} \
--with-mimedir=%{_sysconfdir}/cups \
--with-docdir=%{_defaultdocdir}/%{name} \
--with-htmldir=%{_defaultdocdir}/%{name} \
@@ -477,35 +574,28 @@ sed -i 's|ppd/hpcups/\*.ppd.gz ||g' Makefile
# Make and install Python compiled bytecode files
%py_compile -O %{buildroot}%{_datadir}/hplip
# Hardlink .pyc and .pyo when they have same content.
# Do not run "fdupes buildroot/_datadir/hplip" because
# fdupes will link any files with same content there
# which can have unexpected side-effects, compare
# https://bugzilla.opensuse.org/show_bug.cgi?id=784670
# E.g. fdupes may create links between files that belong
# to different subpackages.
for pyc in $( find %{buildroot}%{_datadir}/hplip -name '*.pyc' )
do
pyo="${pyc%.pyc}.opt-1.pyc"
if test -f $pyo && cmp -s $pyc $pyo
then echo hardlinking $pyc and $pyo because both have same content
ln -f $pyc $pyo
if test -f "$pyo" && cmp -s "$pyc" "$pyo"
then
ln -f "$pyc" "$pyo"
fi
done
# HPLIP's "make install" installs -rw-r--r-- usr/share/hplip/fax/pstotiff
# and usr/lib/cups/filter/pstotiff -> usr/share/hplip/fax/pstotiff
# so that when the CUPS filter usr/lib/cups/filter/pstotiff is called,
# it cannot execute usr/share/hplip/fax/pstotiff which is fixed hereby
# (see https://bugs.launchpad.net/hplip/+bug/1064247 and bnc#783810):
# see https://bugs.launchpad.net/hplip/+bug/1064247 and bnc#783810
chmod a+x %{buildroot}%{_datadir}/hplip/fax/pstotiff
# The /var/lib/hp directory is created everywhere except on openSUSE 12.2 and later versions
# (perhaps an autoconf issue) so that it is created here as simple and fail-safe workaround
# see https://bugs.launchpad.net/bugs/1018303 and bnc#780413
# using fixed "/var/log/hp" because this is hardcoded in the HPLIP sources
# regarding owner and permissions see the "files hpijs" section below
# and Patch102 no-chgrp_lp_hplip_Logdir.diff:
test -d %{buildroot}%{_localstatedir}/lib/hp || install -d %{buildroot}%{_localstatedir}/lib/hp
# Create a /var/log/hp/tmp/ directory that is needed by hp-sendfax
# as a workaround until HPLIP upstream implemented it correctly
# see https://bugzilla.novell.com/show_bug.cgi?id=800312
# and https://bugs.launchpad.net/bugs/1016507
install -d %{buildroot}%{_localstatedir}/log/hp/tmp
@@ -525,131 +615,84 @@ rm %{buildroot}%{_datadir}/hal/fdi/preprobe/10osvendor/20-hplip-devices.fdi
# while in contrast manual printer setup via hp-setup usually "just works"
# and it is clear for the user what goes on and in case of failure what went wrong.
rm %{buildroot}%{_unitdir}/hplip-printer@.service
# Remove selinux configurations we are not supporting on SUSE
# force for not on all distributions the files were installed
# Can't be disabled during configure
rm -f %{buildroot}/%{name}.{fc,if,pp,te}
# Begin "General tests and adjustments for all PPDs" (see manufacturer-PPDs.spec):
pushd %{buildroot}%{_datadir}/cups/model/manufacturer-PPDs/%{name}
# Do not pollute the build log file with zillions of meaningless messages:
set +x
gunzip *.ppd.gz
# Make some general tests and adjustments for all PPDs:
echo "Making some general tests and adjustments for all PPDs:"
# Add a line-feed to the end of all PPDs to fix those PPDs where it is missing.
# See Novell/Suse Bugzilla bug #309832: Unix/Linux text files must end with a line-feed.
# Otherwise reading the last line results EOF and then some programs may ignore the last line.
echo "Adding a line-feed to the end of all PPDs to fix those PPDs where it is missing..."
for p in *.ppd
do echo -en '\n' >>$p
done
# Because foomatic-rip-hplip has CVE-2011-2697 (bnc#698451) plus a leftover in CVE-2004-0801 (bnc#59233)
# foomatic-rip-hplip is no longer installed and foomatic-rip from foomatic-filters or cups-filters-foomatic-rip
# is used instead so that the "cupsFilter" entries in the static PPDs must be changed accordingly:
echo "Replacing insecure foomatic-rip-hplip with foomatic-rip everywhere in in the PPDs..."
for p in *.ppd
do sed -i -e 's/foomatic-rip-hplip/foomatic-rip/' $p
done
# Final test by cupstestppd:
# To save disk space gzip the files (gzipped PPDs can also be used by CUPS).
# Future goal: Only have files which don't FAIL for cupstestppd.
# Ignore FAILs because of errors in UIConstraints and/or NonUIConstraints
# which are detected since cupstestppd in CUPS > 1.2.7 (i.e. in openSUSE 10.3).
# See Novell/Suse Bugzilla bug #309822: When this bug is fixed, cupstestppd would
# no longer result zero exit code.
# In the long run the PPDs should be fixed but as far as we know there have been
# no problems because of such UIConstraints errors so that it should be o.k.
# let those PPDs pass even if they are not strictly compliant.
# Ignore FAILs because of missing cupsFilter programs because
# in the package build environment the usual HPLIP filters
# like "hpcups" and "hpcupsfax" are
# installed at an unusual place (in the BuildRoot directory).
# For now keep all PPDs even if cupstestppd FAILs.
# Reason:
# With each CUPS version upgrade cupstestppd finds more and more errors
# so that more and more PPDs would be no longer included in the RPM
# which have been included before which results a regression.
# As far as we know there have been no problems at all because of
# not strictly compliant PPDs in HPLIP so that it is much better
# to provide all HPLIP PPDs so that the matching printers can be used
# than to be rigorous regarding enforcing compliance to the PPD specification:
echo "Final testing by cupstestppd..."
for p in *.ppd
do grep -E -v '^\*UIConstraints:|^\*NonUIConstraints:|^\*cupsFilter:' $p | cupstestppd - || true
gzip -n -9 $p
done
echo "Moving PPDs that use the hpps filter to %{_datadir}/cups/model/manufacturer-PPDs/hplip-hpps..."
# PPDs for various printers that use the hpps filter
# must be moved to the hplip main-package because
# the /usr/lib/cups/filter/hpps Python script imports
# various HPLIP modules from the hplip main-package
# so that the hpps filter belongs to the hplip main-package
# (see https://bugzilla.novell.com/show_bug.cgi?id=876690).
# Accordingly the PPDs that use the hpps filter must be moved
# to the hplip main-package which is implemented by moving them
# to a new directory /usr/share/cups/model/manufacturer-PPDs/hplip-hpps
# that is listed in the files list of the hplip main-package:
# Create appropriate sub-directories for PPDs:
install -d %{buildroot}%{_datadir}/cups/model/manufacturer-PPDs/%{name}-ps
install -d %{buildroot}%{_datadir}/cups/model/manufacturer-PPDs/%{name}-hpps
for p in *.ppd.gz
do zgrep -q '^\*cupsFilter:.*hpps' $p && mv $p ../%{name}-hpps
done
echo "Moving PPDs that require a proprietary plugin from HP to %{_datadir}/cups/model/manufacturer-PPDs/hplip-plugin..."
# PPDs for various printers that require a proprietary plugin from HP
# must be moved to the hplip main-package because
# the proprietary plugin from HP must be downloaded and installed
# by using HP's "hp-plugin" tool from the hplip main-package
# (HP's "hp-setup" tool calls "hp-plugin" when needed).
# Accordingly PPDs that require a proprietary plugin from HP must be moved
# to the hplip main-package which is implemented by moving them
# to a new directory /usr/share/cups/model/manufacturer-PPDs/hplip-plugin
# that is listed in the files list of the hplip main-package
# (see https://bugzilla.novell.com/show_bug.cgi?id=876690):
install -d %{buildroot}%{_datadir}/cups/model/manufacturer-PPDs/%{name}-plugin
for p in *.ppd.gz
do zgrep -q '^\*NickName:.*requires proprietary plugin' $p && mv $p ../%{name}-plugin
install -d %{buildroot}%{_datadir}/cups/model/manufacturer-PPDs/%{name}-hpcups
install -d %{buildroot}%{_datadir}/cups/model/manufacturer-PPDs/%{name}-fax
gunzip *.ppd.gz
for p in *.ppd
do
# Add a line-feed to the end of all PPDs to fix those PPDs where it is missing.
# See Novell/Suse Bugzilla bug #309832: Unix/Linux text files must end with a line-feed.
# Otherwise reading the last line results EOF and then some programs may ignore the last line:
echo -en '\n' >>"$p"
# Move PPDs into appropriate sub-directories:
if grep -q '^\*NickName:.*requires proprietary plugin' "$p"; then
dir=../%{name}-plugin
else
filter=$( grep -m1 cupsFilter "$p" ) || true
case $filter in
*foomatic-rip*)
# Skip 'hpijs' PPDs which are those that use foomatic-rip as cupsFilter
# see https://bugzilla.suse.com/show_bug.cgi?id=1250481#c1
continue;;
*hpcupsfax*|*hpcdmfax*)
dir=../%{name}-fax;;
*hpcups*)
dir=../%{name}-hpcups;;
*hpps*)
dir=../%{name}-hpps;;
"")
dir=../%{name}-ps;;
esac
fi
gzip -n -9 "$p"
mv -f "$p.gz" "$dir"
done
echo "End of general tests and adjustments for all PPDs."
# Switch back to the usual build log messages:
set -x
# End of "General tests and adjustments for all PPDs":
popd
# Replace the invalid Desktop categories
%if %{with update_desktop}
%suse_update_desktop_file -r %{buildroot}%{_datadir}/applications/hplip.desktop System HardwareSettings
%suse_update_desktop_file -r %{buildroot}%{_datadir}/applications/hp-uiscan.desktop System HardwareSettings
# Let suse_update_desktop_file add X-SuSE-translate key to /etc/xdg/autostart/hplip-systray.desktop
# so that we can update its translations with translation-only packages.
%suse_update_desktop_file -i %{buildroot}%{_sysconfdir}/xdg/autostart/hplip-systray.desktop
%endif
# End of "Desktop menue entry stuff".
# Install the man page for /usr/bin/hpijs:
install -d %{buildroot}%{_mandir}/man1
install -m 644 %{SOURCE102} %{buildroot}%{_mandir}/man1/
# remove libtool archives
# Remove libtool archives:
find "%{buildroot}" -type f -name "*.la" -delete -print
# Run fdupes:
# The RPM macro fdupes runs /usr/bin/fdupes that links files with identical content.
# Never run fdupes carelessly over the whole buildroot directory
# because in older openSUSE and SLE11 versions fdupes
# links files with different owner, group, or permissions
# see https://bugzilla.novell.com/show_bug.cgi?id=784670
# and even in current openSUSE versions fdupes links across sub-package boundaries,
# compare https://bugzilla.novell.com/show_bug.cgi?id=784869
# so that fdupes can only run for specific directories where linking files is safe:
# Run fdupes only on the images subdir to avoid broken symlinks in subpackages:
%fdupes -s %{buildroot}%{_datadir}/hplip/data/images
%post -p /bin/bash
%udev_rules_update
%desktop_database_post
%icon_theme_cache_post
/sbin/ldconfig
exit 0
# Ensure we have no unpackaged files if build without scan-util:
%if !%{with scan_utils}
rm -f %{buildroot}%{_bindir}/hp-scan
rm -f %{buildroot}%{_bindir}/hp-uiscan
rm -f %{buildroot}%{python_sitearch}/scanext.so
rm -f %{buildroot}%{_datadir}/applications/hp-uiscan.desktop
%endif
%postun -p /bin/bash
%desktop_database_postun
%icon_theme_cache_postun
/sbin/ldconfig
%post common
%udev_rules_update
%postun sane
# Earlier versions of hplip modified /etc/sane.d/dll.conf
@@ -661,67 +704,57 @@ if [ "$1" = "0" ] && [ -w %{_sysconfdir}/sane.d/dll.conf ]; then
fi
exit 0
%post hpijs -p /bin/bash
/sbin/ldconfig
exit 0
%post -n libhplip0 -p %{run_ldconfig}
%postun -n libhplip0 -p %{run_ldconfig}
%postun hpijs -p /bin/bash
/sbin/ldconfig
exit 0
%post base -p %{run_ldconfig}
%postun base -p %{run_ldconfig}
%files
%config %{_sysconfdir}/xdg/autostart/hplip-systray.desktop
%{_bindir}/hp-align
%{_bindir}/hp-check
%{_bindir}/hp-clean
%{_bindir}/hp-colorcal
%{_bindir}/hp-config_usb_printer
%{_bindir}/hp-devicesettings
%{_bindir}/hp-diagnose_plugin
%{_bindir}/hp-diagnose_queues
%{_bindir}/hp-doctor
%{_bindir}/hp-fab
%{_bindir}/hp-faxsetup
%{_bindir}/hp-firmware
%{_bindir}/hp-info
%{_bindir}/hp-levels
%{_bindir}/hp-linefeedcal
%{_bindir}/hp-logcapture
%{_bindir}/hp-makecopies
%{_bindir}/hp-makeuri
%{_bindir}/hp-pkservice
%{_bindir}/hp-plugin
%{_bindir}/hp-pqdiag
%{_bindir}/hp-print
%{_bindir}/hp-printsettings
%{_bindir}/hp-probe
%{_bindir}/hp-query
%{_bindir}/hp-sendfax
%{_bindir}/hp-setup
%{_bindir}/hp-systray
%{_bindir}/hp-testpage
%{_bindir}/hp-timedate
%{_bindir}/hp-toolbox
%{_bindir}/hp-uninstall
%{_bindir}/hp-unload
%{_bindir}/hp-upgrade
%{_bindir}/hp-wificonfig
# empty
%files base
%(for _x in %{basic_tools}; do echo "%{_bindir}/hp-$_x"; done)
%(for _x in %{basic_tools}; do echo "%{_datadir}/hplip/$_x.py"; done)
%(for _x in %{basic_tools}; do echo "%{_datadir}/hplip/__pycache__/$_x.*"; done)
%{_datadir}/hplip/base
%exclude %{_datadir}/hplip/base/imageprocessing.py*
%exclude %{_datadir}/hplip/base/__pycache__/imageprocessing.*
%{_datadir}/hplip/fax
%{_datadir}/hplip/installer
%{_datadir}/hplip/prnt
%{_libdir}/python%{pyver}/site-packages/cupsext.*
%{_libdir}/python%{pyver}/site-packages/hpmudext.*
%{_libdir}/python%{pyver}/site-packages/pcardext.*
%dir %{_prefix}/lib/cups
%dir %{_prefix}/lib/cups/backend
%{_prefix}/lib/cups/backend/hpfax
%dir %{_prefix}/lib/cups/filter
%{_prefix}/lib/cups/filter/hpps
%dir %{_datadir}/cups
%dir %{_datadir}/cups/model
%dir %{_datadir}/cups/model/manufacturer-PPDs
%{_datadir}/cups/model/manufacturer-PPDs/%{name}-hpps/
%{_datadir}/cups/model/manufacturer-PPDs/%{name}-plugin/
%files utils
%config %{_sysconfdir}/xdg/autostart/hplip-systray.desktop
# GUI tools (not in the basic_tools list above)
%{_bindir}/hp-check
%{_bindir}/hp-config_usb_printer
%{_bindir}/hp-devicesettings
%{_bindir}/hp-diagnose_plugin
%{_bindir}/hp-faxsetup
%{_bindir}/hp-linefeedcal
%{_bindir}/hp-pqdiag
%{_bindir}/hp-print
%{_bindir}/hp-printsettings
%{_bindir}/hp-systray
%{_bindir}/hp-toolbox
%{_bindir}/hp-wificonfig
# Fixme: these tools are useless on openSUSE.
%{_bindir}/hp-pkservice
%{_bindir}/hp-uninstall
%{_bindir}/hp-upgrade
%doc %{_defaultdocdir}/%{name}/
%{_datadir}/applications/%{name}.desktop
%{_datadir}/hplip/
%{expand:%(for _x in %{basic_tools}; do echo "%%exclude %{_datadir}/hplip/$_x.py"; done)}
%{expand:%(for _x in %{basic_tools}; do echo "%%exclude %{_datadir}/hplip/__pycache__/$_x.*"; done)}
%exclude %{_datadir}/hplip/base
%exclude %{_datadir}/hplip/fax
%exclude %{_datadir}/hplip/installer
%exclude %{_datadir}/hplip/prnt
%exclude %{_datadir}/hplip/data/models/models.dat
%exclude %{_datadir}/hplip/base/imageprocessing.py*
%exclude %{_datadir}/hplip/%{ui_dir}/scandialog.py*
@@ -733,6 +766,7 @@ exit 0
%exclude %{_datadir}/hplip/base/__pycache__/imageprocessing.*
%exclude %{_datadir}/hplip/%{ui_dir}/__pycache__/scandialog.*
%if %{with scan_utils}
# The scanning utils depend on PIL and python3-scikit-image,
# which are not available in SLE
%files scan-utils
@@ -751,30 +785,17 @@ exit 0
%{_datadir}/hplip/base/__pycache__/imageprocessing.*
%{_datadir}/hplip/%{ui_dir}/__pycache__/scandialog.*
%endif
%endif
%files hpijs
%files common
%config %{_sysconfdir}/hp/
%config %{_sysconfdir}/cups/pstotiff.convs
%config %{_sysconfdir}/cups/pstotiff.types
%{_bindir}/hpijs
%{_mandir}/man1/hpijs.1%{?ext_man}
%{_libdir}/libhpip.so.*
%{_libdir}/libhpipp.so.*
%{_libdir}/libhpmud.so.*
%{_libdir}/libhpdiscovery.so.*
%dir %{_prefix}/lib/cups
%dir %{_prefix}/lib/cups/backend
%{_prefix}/lib/cups/backend/hp
%dir %{_prefix}/lib/cups/filter
%{_prefix}/lib/cups/filter/hpcups
%{_prefix}/lib/cups/filter/hpcupsfax
%{_prefix}/lib/cups/filter/hpcdmfax
%{_prefix}/lib/cups/filter/pstotiff
%{_datadir}/%{name}/data/models/models.dat
%{_udevrulesdir}/56-hpmud.rules
%dir %{_datadir}/cups
%dir %{_datadir}/cups/model
%dir %{_datadir}/cups/model/manufacturer-PPDs
%{_datadir}/cups/model/manufacturer-PPDs/%{name}/
%{_datadir}/%{name}/data/models/models.dat
# Use fixed "/var/log/hp" because this is hardcoded in the HPLIP sources.
# Regarding attr(0775,root,lp) see the comment for /var/log/hp/tmp below:
%dir %attr(0775,root,lp) %{_localstatedir}/log/hp
@@ -785,15 +806,48 @@ exit 0
# Use fixed "/var/lib/hp" because this is hardcoded in the HPLIP sources:
%dir %{_localstatedir}/lib/hp
%files -n libhplip0
%{_libdir}/libhpip.so.*
%{_libdir}/libhpipp.so.*
%{_libdir}/libhpmud.so.*
%{_libdir}/libhpdiscovery.so.*
%files cups
%dir %{_prefix}/lib/cups/filter
%{_prefix}/lib/cups/filter/hpps
%{_prefix}/lib/cups/filter/hpcups
%{_prefix}/lib/cups/filter/hpcupsfax
%{_prefix}/lib/cups/filter/hpcdmfax
%{_prefix}/lib/cups/filter/pstotiff
%dir %{_prefix}/lib/cups/backend
%{_prefix}/lib/cups/backend/hp
%{_prefix}/lib/cups/backend/hpfax
%files driver-hpcups
%dir %{drvdir}
%{drvdir}/hpcups.drv
%files ppds-hpcups
%{_datadir}/cups/model/manufacturer-PPDs/%{name}-hpcups
%files ppds-hpps
%{_datadir}/cups/model/manufacturer-PPDs/%{name}-hpps
%files ppds-postscript
%{_datadir}/cups/model/manufacturer-PPDs/%{name}-ps
%files ppds-plugin
%{_datadir}/cups/model/manufacturer-PPDs/%{name}-plugin
%files ppds-fax
%{_datadir}/cups/model/manufacturer-PPDs/%{name}-fax
%files sane
%dir %{_libdir}/sane
%{_libdir}/sane/libsane-hpaio.so.*
%dir %{_sysconfdir}/sane.d
%dir %{_sysconfdir}/sane.d/dll.d
%{_sysconfdir}/sane.d/dll.d/hpaio
%files udev-rules
%{_udevrulesdir}/56-hpmud.rules
%config %{_sysconfdir}/sane.d/dll.d/hpaio
%files devel
%{_libdir}/libhpip.so