[arch-commits] Commit in cups/trunk (PKGBUILD samsung-printer-workaround.patch)
Andreas Radke
andyrtr at archlinux.org
Tue Apr 16 05:27:17 UTC 2019
Date: Tuesday, April 16, 2019 @ 05:27:16
Author: andyrtr
Revision: 350799
upgpkg: cups 2.2.11-2
apply upstream fix to make samsung printer working again FS#62360
Added:
cups/trunk/samsung-printer-workaround.patch
Modified:
cups/trunk/PKGBUILD
----------------------------------+
PKGBUILD | 11 ++++++++---
samsung-printer-workaround.patch | 30 ++++++++++++++++++++++++++++++
2 files changed, 38 insertions(+), 3 deletions(-)
Modified: PKGBUILD
===================================================================
--- PKGBUILD 2019-04-16 04:53:52 UTC (rev 350798)
+++ PKGBUILD 2019-04-16 05:27:16 UTC (rev 350799)
@@ -3,7 +3,7 @@
pkgbase="cups"
pkgname=('libcups' 'cups')
pkgver=2.2.11
-pkgrel=1
+pkgrel=2
arch=('x86_64')
license=('GPL')
url="https://www.cups.org/"
@@ -20,7 +20,8 @@
cups-1.6.2-statedir.patch
# bugfixes
cups-systemd-socket.patch
- guid.patch)
+ guid.patch
+ samsung-printer-workaround.patch)
sha256sums=('f58010813fd6903f690cdb0c0b91e4d1bc9e5b9570c28734229ba3ed2908b76c'
'SKIP'
'd87fa0f0b5ec677aae34668f260333db17ce303aa1a752cba5f8e72623d9acf9'
@@ -30,7 +31,8 @@
'b8fc2e3bc603495f0278410350ea8f0161d9d83719feb64f573b63430cb4800b'
'23349c96f2f7aeb7d48e3bcd35a969f5d5ac8f55a032b0cfaa0a03d7e37ea9af'
'f909719e2595e016c320afa421cad74ccda285ac59b11749ddac58e707d4330a'
- 'd4537526c1e075866ae22ad263da000fc2a592d36c26b79a459a1cfdade2bb2d')
+ 'd4537526c1e075866ae22ad263da000fc2a592d36c26b79a459a1cfdade2bb2d'
+ 'ae3e154b8382f3412c73d863f4db095e722eb5255e15f0684b2bb9e02e5438af')
validpgpkeys=('3737FD0D0E63B30172440D2DDBA3A7AB08D76223') # CUPS.org (CUPS.org PGP key) <security at cups.org>
validpgpkeys+=('45D083946E3035282B3CCA9AF434104235DA97EB') # "CUPS.org <security at cups.org>"
validpgpkeys+=('845464660B686AAB36540B6F999559A027815955') # "Michael R Sweet <michael.r.sweet at gmail.com>"
@@ -54,6 +56,9 @@
# FS#56818 - https://github.com/apple/cups/issues/5236
patch -Np1 -i ${srcdir}/guid.patch
+ # FS#62360 / https://github.com/apple/cups/issues/5562
+ patch -Np1 -i ${srcdir}/samsung-printer-workaround.patch
+
# set MaxLogSize to 0 to prevent using cups internal log rotation
sed -i -e '5i\ ' conf/cupsd.conf.in
sed -i -e '6i# Disable cups internal logging - use logrotate instead' conf/cupsd.conf.in
Added: samsung-printer-workaround.patch
===================================================================
--- samsung-printer-workaround.patch (rev 0)
+++ samsung-printer-workaround.patch 2019-04-16 05:27:16 UTC (rev 350799)
@@ -0,0 +1,30 @@
+diff --git a/cups/ppd.c b/cups/ppd.c
+index 435b992f4..29456d97a 100644
+--- a/cups/ppd.c
++++ b/cups/ppd.c
+@@ -1182,6 +1182,24 @@ _ppdOpen(
+ else if (!strcmp(string, "Plus90"))
+ ppd->landscape = 90;
+ }
++ else if (!strcmp(keyword, "Emulators") && string && ppd->num_emulations == 0)
++ {
++ /*
++ * Issue #5562: Samsung printer drivers incorrectly use Emulators keyword
++ * to configure themselves
++ *
++ * The Emulators keyword was loaded but never used by anything in CUPS,
++ * and has no valid purpose in CUPS. The old code was removed due to a
++ * memory leak (Issue #5475), so the following (new) code supports a single
++ * name for the Emulators keyword, allowing these drivers to work until we
++ * remove PPD and driver support entirely in a future version of CUPS.
++ */
++
++ ppd->num_emulations = 1;
++ ppd->emulations = calloc(1, sizeof(ppd_emul_t));
++
++ strlcpy(ppd->emulations[0].name, string, sizeof(ppd->emulations[0].name));
++ }
+ else if (!strcmp(keyword, "JobPatchFile"))
+ {
+ /*
+
More information about the arch-commits
mailing list