From 982e968ef61a94e0de75d733e9036e5c60afca34 Mon Sep 17 00:00:00 2001 From: Tijl Coosemans Date: Wed, 25 Aug 2021 15:29:51 +0200 Subject: print/hplip(-plugin): update to 3.22.2 - Convert post-patch to real patches because they are easier to maintain. - Fix a NULL dereference in the scanner backend when D-Bus isn't running. - Depend on sysutils/py-distro to make hp-toolbox (Device Manager) work again. - Upstream switched to Avahi for mDNS support. Rename the SNMP option to NETWORK because it's not just SNMP now. - Don't install some programs related to uninstalling and upgrading of HPLIP and the installation of firmware plugins because they circumvent the package system. - Install icons in share/icons so desktops can choose an appropriate resolution. Portions taken from a patch by Oleg Sidorkin . PR: 255586, 257034, 257512 --- print/hplip/files/patch-base_g.py | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 print/hplip/files/patch-base_g.py (limited to 'print/hplip/files/patch-base_g.py') diff --git a/print/hplip/files/patch-base_g.py b/print/hplip/files/patch-base_g.py new file mode 100644 index 000000000000..5a7147a8f2de --- /dev/null +++ b/print/hplip/files/patch-base_g.py @@ -0,0 +1,29 @@ +--- base/g.py.orig 2022-02-23 07:41:04 UTC ++++ base/g.py +@@ -143,7 +143,7 @@ class ConfigBase(object): + def write(self): + if self.filename is not None: + filename = self.filename +- if filename.startswith("/root/") or filename.startswith("/etc/"): ++ if filename.startswith("/root/") or filename.startswith("/etc/") or filename.startswith("/usr/local/etc/"): + # Don't try writing a file in root's home directory or + # the system-wide config file. + # See bug #479178. +@@ -182,7 +182,7 @@ class ConfigBase(object): + + class SysConfig(ConfigBase): + def __init__(self): +- ConfigBase.__init__(self, '/etc/hp/hplip.conf') ++ ConfigBase.__init__(self, '/usr/local/etc/hp/hplip.conf') + + + class State(ConfigBase): +@@ -343,7 +343,7 @@ def check_extension_module_env(ext_mod): + else : + python_ver = 2 + +- for dirpath, dirname, filenames in os.walk('/usr/lib/'): #find the .so path ++ for dirpath, dirname, filenames in os.walk('/usr/local/lib/'): #find the .so path + if ext_mod_so in filenames: + ext_path = dirpath + flag = 1 -- cgit v1.2.3