From c2273c9cee7d0b45cbf582886f89600280af0392 Mon Sep 17 00:00:00 2001 From: Tim Waugh Date: Thu, 8 Jan 2009 18:04:56 +0000 Subject: [PATCH] - Updated pycups to 1.9.45. --- .cvsignore | 1 + pycups-1.9.44.tar.bz2.sig | Bin 65 -> 0 bytes pycups-1.9.45.tar.bz2.sig | Bin 0 -> 65 bytes pycups-git.patch | 113 ------------------------------------- sources | 2 +- system-config-printer.spec | 12 ++-- 6 files changed, 7 insertions(+), 121 deletions(-) delete mode 100644 pycups-1.9.44.tar.bz2.sig create mode 100644 pycups-1.9.45.tar.bz2.sig delete mode 100644 pycups-git.patch diff --git a/.cvsignore b/.cvsignore index 87278ae..b87b6c9 100644 --- a/.cvsignore +++ b/.cvsignore @@ -192,3 +192,4 @@ pycups-1.9.44.tar.bz2 system-config-printer-1.0.12.tar.bz2 system-config-printer-1.1.0.tar.bz2 system-config-printer-1.1.1.tar.bz2 +pycups-1.9.45.tar.bz2 diff --git a/pycups-1.9.44.tar.bz2.sig b/pycups-1.9.44.tar.bz2.sig deleted file mode 100644 index e43fadfb67f02490df9e6ff6657f60b3ea8543ca..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 65 zcmV-H0KWf-KLZ5-NiXCDX(f@P9=Dkz5ds>z0H1p0TtQhR{}Fe6i%x!R1BJRr05<@i XM2Xce_6vOb>g6O^Bx)!#7_LRG`1cs$ diff --git a/pycups-1.9.45.tar.bz2.sig b/pycups-1.9.45.tar.bz2.sig new file mode 100644 index 0000000000000000000000000000000000000000..af3a7151dd5866ae16f4a4ca0f69097588976f1b GIT binary patch literal 65 zcmV-H0KWf-KLZ5-NoF*(X(f@P9=Dkz5d!L}0HBJ!lzsTKRPf$-yi&xR87#_5js*an X9#ti!p68{d^RTRWeM2j9=~~Q4k%}H2 literal 0 HcmV?d00001 diff --git a/pycups-git.patch b/pycups-git.patch deleted file mode 100644 index 5322891..0000000 --- a/pycups-git.patch +++ /dev/null @@ -1,113 +0,0 @@ -diff -U0 pycups-1.9.44/ChangeLog.pycups-git pycups-1.9.44/ChangeLog ---- pycups-1.9.44/ChangeLog.pycups-git 2008-11-28 12:27:15.000000000 +0000 -+++ pycups-1.9.44/ChangeLog 2008-12-17 16:36:03.000000000 +0000 -@@ -0,0 +1,16 @@ -+2008-12-17 Tim Waugh -+ -+ * cupsconnection.c (Connection_printTestPage): Look for -+ "testprint" as well as "testprint.ps", as that is the name of the -+ test page file in CUPS 1.4 (bug #476612). -+ -+2008-12-17 Tim Waugh -+ -+ * cupsconnection.c (Connection_printTestPage): Only set a -+ document-format attribute if one is specified. -+ -+2008-12-17 Tim Waugh -+ -+ * cupsconnection.c (Connection_printTestPage): Avoid crash when -+ given bad parameters. -+ -diff -up pycups-1.9.44/cupsconnection.c.pycups-git pycups-1.9.44/cupsconnection.c ---- pycups-1.9.44/cupsconnection.c.pycups-git 2008-11-25 12:12:38.000000000 +0000 -+++ pycups-1.9.44/cupsconnection.c 2008-12-17 16:36:03.000000000 +0000 -@@ -2908,13 +2908,13 @@ Connection_printTestPage (Connection *se - PyObject *printerobj; - char *printer; - PyObject *fileobj = NULL; -- char *file; -+ char *file = NULL; - PyObject *titleobj = NULL; -- char *title; -+ char *title = NULL; - PyObject *formatobj = NULL; -- char *format; -+ char *format = NULL; - PyObject *userobj = NULL; -- char *user; -+ char *user = NULL; - const char *datadir; - char filename[PATH_MAX]; - char uri[HTTP_MAX_URI]; -@@ -2946,17 +2946,33 @@ Connection_printTestPage (Connection *se - } - - if (!fileobj) { -- const char *testprint = "%s/data/testprint.ps"; -- if ((datadir = getenv ("CUPS_DATADIR")) != NULL) -- snprintf (filename, sizeof (filename), testprint, datadir); -- else { -+ const char *testprint[] = { "%s/data/testprint", -+ "%s/data/testprint.ps", -+ NULL }; -+ if ((datadir = getenv ("CUPS_DATADIR")) != NULL) { -+ const char **pattern; -+ for (pattern = testprint; *pattern != NULL; pattern++) { -+ snprintf (filename, sizeof (filename), *pattern, datadir); -+ if (access (filename, R_OK) == 0) -+ break; -+ } -+ } else { - const char *const dirs[] = { "/usr/share/cups", - "/usr/local/share/cups", - NULL }; -+ int found = 0; - int i; - for (i = 0; (datadir = dirs[i]) != NULL; i++) { -- snprintf (filename, sizeof (filename), testprint, datadir); -- if (access (filename, R_OK) == 0) -+ const char **pattern; -+ for (pattern = testprint; *pattern != NULL; pattern++) { -+ snprintf (filename, sizeof (filename), *pattern, datadir); -+ if (access (filename, R_OK) == 0) { -+ found = 1; -+ break; -+ } -+ } -+ -+ if (found) - break; - } - -@@ -2966,7 +2982,7 @@ Connection_printTestPage (Connection *se - * client-error-not-found, but we'll let that happen rather - * than raising an exception so as to be consistent with the - * case where CUPS_DATADIR is set and we trust it. */ -- snprintf (filename, sizeof (filename), testprint, dirs[0]); -+ snprintf (filename, sizeof (filename), testprint[0], dirs[0]); - } - - file = filename; -@@ -2975,9 +2991,6 @@ Connection_printTestPage (Connection *se - if (!titleobj) - title = "Test Page"; - -- if (!formatobj) -- format = "application/postscript"; -- - if (!userobj) - user = (char *) cupsUser(); - -@@ -2991,8 +3004,10 @@ Connection_printTestPage (Connection *se - "requesting-user-name", NULL, user); - ippAddString (request, IPP_TAG_OPERATION, IPP_TAG_NAME, "job-name", - NULL, title); -- ippAddString (request, IPP_TAG_JOB, IPP_TAG_MIMETYPE, "document-format", -- NULL, format); -+ if (format) -+ ippAddString (request, IPP_TAG_JOB, IPP_TAG_MIMETYPE, "document-format", -+ NULL, format); -+ - Connection_begin_allow_threads (self); - answer = cupsDoFileRequest (self->http, request, resource, file); - Connection_end_allow_threads (self); diff --git a/sources b/sources index 34d1e52..d222bb1 100644 --- a/sources +++ b/sources @@ -1,3 +1,3 @@ ac8f98a40b0fc4b6ab4470f10489887a pysmbc-1.0.6.tar.bz2 -181f413546676e098352860e3ce57465 pycups-1.9.44.tar.bz2 95ad721f3d274557144ddcf5e458a9e4 system-config-printer-1.1.1.tar.bz2 +ff634a6751f8a859ed26751bf03abef0 pycups-1.9.45.tar.bz2 diff --git a/system-config-printer.spec b/system-config-printer.spec index d10f73e..9a752fd 100644 --- a/system-config-printer.spec +++ b/system-config-printer.spec @@ -1,4 +1,4 @@ -%define pycups_version 1.9.44 +%define pycups_version 1.9.45 %define pysmbc_version 1.0.6 %{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")} %{!?python_sitearch: %define python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")} @@ -7,7 +7,7 @@ Summary: A printer administration tool Name: system-config-printer Version: 1.1.1 -Release: 1%{?dist} +Release: 2%{?dist} License: GPLv2+ URL: http://cyberelk.net/tim/software/system-config-printer/ Group: System Environment/Base @@ -15,8 +15,6 @@ 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 -Patch10: pycups-git.patch - BuildRequires: cups-devel >= 1.2 BuildRequires: python-devel >= 2.4 BuildRequires: libsmbclient-devel >= 3.2 @@ -62,9 +60,6 @@ the configuration tool. %prep %setup -q -a 1 -a 2 -pushd pycups-%{pycups_version} -%patch10 -p1 -b .pycups-git -popd %build %configure @@ -164,6 +159,9 @@ rm -rf %buildroot exit 0 %changelog +* Thu Jan 8 2009 Tim Waugh 1.1.1-2 +- Updated pycups to 1.9.45. + * Sat Dec 20 2008 Tim Waugh 1.1.1-1 - 1.1.1.