From dba4e31faa9bdac3347ce97809d73f4eac0c0bc2 Mon Sep 17 00:00:00 2001 From: Tim Waugh Date: Fri, 14 Aug 2009 15:03:14 +0000 Subject: [PATCH] - Compare MFG and MDL fields case insensitively when adding automatic queues, because HPLIP provides them with different case than the actual devices do. Upstream HPLIP bug: https://bugs.launchpad.net/hplip/+bug/405804 --- system-config-printer-hplip-hack.patch | 14 ++++++++++++++ system-config-printer.spec | 10 +++++++++- 2 files changed, 23 insertions(+), 1 deletion(-) create mode 100644 system-config-printer-hplip-hack.patch diff --git a/system-config-printer-hplip-hack.patch b/system-config-printer-hplip-hack.patch new file mode 100644 index 0000000..302995f --- /dev/null +++ b/system-config-printer-hplip-hack.patch @@ -0,0 +1,14 @@ +diff -up system-config-printer-1.1.11/udev/udev-configure-printer.c.hplip-hack system-config-printer-1.1.11/udev/udev-configure-printer.c +--- system-config-printer-1.1.11/udev/udev-configure-printer.c.hplip-hack 2009-08-07 17:42:55.000000000 +0100 ++++ system-config-printer-1.1.11/udev/udev-configure-printer.c 2009-08-14 15:50:32.302334316 +0100 +@@ -791,8 +791,8 @@ find_matching_device_uris (struct device + + /* Now check the manufacturer and model names. */ + if (device_uri && this_id.mfg && this_id.mdl && +- !strcmp (this_id.mfg, id->mfg) && +- !strcmp (this_id.mdl, id->mdl)) ++ !strcasecmp (this_id.mfg, id->mfg) && ++ !strcasecmp (this_id.mdl, id->mdl)) + { + /* We've checked everything except the serial numbers. This + * is more complicated. Some devices include a serial diff --git a/system-config-printer.spec b/system-config-printer.spec index 0319faa..663f4bd 100644 --- a/system-config-printer.spec +++ b/system-config-printer.spec @@ -7,7 +7,7 @@ Summary: A printer administration tool Name: system-config-printer Version: 1.1.11 -Release: 3%{?dist} +Release: 4%{?dist} License: GPLv2+ URL: http://cyberelk.net/tim/software/system-config-printer/ Group: System Environment/Base @@ -15,6 +15,7 @@ Source0: http://cyberelk.net/tim/data/system-config-printer/1.1/system-config-pr Source1: http://cyberelk.net/tim/data/pycups/pycups-%{pycups_version}.tar.bz2 Source2: http://cyberelk.net/tim/data/pysmbc/pysmbc-%{pysmbc_version}.tar.bz2 Patch1: system-config-printer-getdevices.patch +Patch2: system-config-printer-hplip-hack.patch BuildRequires: cups-devel >= 1.2 BuildRequires: python-devel >= 2.4 @@ -76,6 +77,7 @@ printers. %prep %setup -q -a 1 -a 2 %patch1 -p1 -b .getdevices +%patch2 -p1 -b .hplip-hack %build %configure --with-udev-rules @@ -188,6 +190,12 @@ rm -rf %buildroot exit 0 %changelog +* Fri Aug 14 2009 Tim Waugh 1.1.11-4 +- Compare MFG and MDL fields case insensitively when adding automatic + queues, because HPLIP provides them with different case than the + actual devices do. Upstream HPLIP bug: + https://bugs.launchpad.net/hplip/+bug/405804 + * Fri Aug 14 2009 Tim Waugh 1.1.11-3 - Own /var/run/udev-configure-printer.