- update to py-cups-1.9.45

- add a small workaround because our CUPS is too old (CUPS will get a major
update on the next dev cycle)

ok jasper@
This commit is contained in:
ajacoutot 2009-01-31 12:36:59 +00:00
parent 56740137f4
commit 75280f8be8
4 changed files with 39 additions and 20 deletions

View File

@ -1,12 +1,12 @@
# $OpenBSD: Makefile,v 1.5 2009/01/02 13:07:37 djm Exp $
# $OpenBSD: Makefile,v 1.6 2009/01/31 12:36:59 ajacoutot Exp $
SHARED_ONLY= Yes
COMMENT= CUPS bindings for Python
VERSION= 1.9.42
VERSION= 1.9.45
DISTNAME= pycups-${VERSION}
PKGNAME= py-cups-${VERSION}p0
PKGNAME= py-cups-${VERSION}
CATEGORIES= print
HOMEPAGE= http://cyberelk.net/tim/software/pycups/

View File

@ -1,5 +1,5 @@
MD5 (pycups-1.9.42.tar.bz2) = AwN51KzMGMQCzR7DZ1JKOw==
RMD160 (pycups-1.9.42.tar.bz2) = 8WpNhTZX+jqws7zUceXYoNDJqfo=
SHA1 (pycups-1.9.42.tar.bz2) = Atw437lC73zl+9HLIBjwr0nlYAw=
SHA256 (pycups-1.9.42.tar.bz2) = Tera581dwpP0YAL+axP51u1dTQAkI66BiHVF42z0m/k=
SIZE (pycups-1.9.42.tar.bz2) = 39157
MD5 (pycups-1.9.45.tar.bz2) = /2NKZ1H4qFntJnUb8Dq+8A==
RMD160 (pycups-1.9.45.tar.bz2) = 0Ds4CA73s4VonBl7Iwh0kUd+T9c=
SHA1 (pycups-1.9.45.tar.bz2) = l26E8aMsvA/D/Fw1V/rTNASOBXM=
SHA256 (pycups-1.9.45.tar.bz2) = 725XblRl2pwzisj/nxYoJc+3mXNZ78UuahEMKVqfNjs=
SIZE (pycups-1.9.45.tar.bz2) = 39968

View File

@ -1,13 +1,13 @@
$OpenBSD: patch-cupsconnection_c,v 1.3 2008/09/17 11:57:44 ajacoutot Exp $
--- cupsconnection.c.orig Fri Aug 29 10:56:45 2008
+++ cupsconnection.c Wed Sep 17 13:44:41 2008
@@ -2862,8 +2862,7 @@ Connection_printTestPage (Connection *self, PyObject *
if ((datadir = getenv ("CUPS_DATADIR")) != NULL)
snprintf (filename, sizeof (filename), testprint, datadir);
else {
$OpenBSD: patch-cupsconnection_c,v 1.4 2009/01/31 12:36:59 ajacoutot Exp $
--- cupsconnection.c.orig Sat Jan 31 12:01:32 2009
+++ cupsconnection.c Sat Jan 31 12:02:05 2009
@@ -2957,8 +2957,7 @@ Connection_printTestPage (Connection *self, PyObject *
break;
}
} else {
- const char *const dirs[] = { "/usr/share/cups",
- "/usr/local/share/cups",
+ const char *const dirs[] = { "${LOCALBASE}/share/cups",
NULL };
int found = 0;
int i;
for (i = 0; (datadir = dirs[i]) != NULL; i++) {

View File

@ -1,7 +1,26 @@
$OpenBSD: patch-cupsppd_c,v 1.1.1.1 2008/04/10 10:21:42 jasper Exp $
--- cupsppd.c.orig Thu Mar 6 11:08:23 2008
+++ cupsppd.c Thu Mar 27 15:36:34 2008
@@ -451,7 +451,7 @@ PPD_nondefaultsMarked (PPD *self)
$OpenBSD: patch-cupsppd_c,v 1.2 2009/01/31 12:36:59 ajacoutot Exp $
--- cupsppd.c.orig Tue Dec 23 18:13:38 2008
+++ cupsppd.c Sat Jan 31 12:57:38 2009
@@ -274,6 +274,10 @@ PPD_localizeIPPReason (PPD *self, PyObject *args, PyOb
return NULL;
buffer = malloc (bufsize);
+#ifdef __OpenBSD__ // we need a newer CUPS
+ ret = Py_None;
+ Py_INCREF (Py_None);
+#else
if (ppdLocalizeIPPReason (self->ppd, reason, scheme, buffer, bufsize))
{
ret = make_PyUnicode_from_ppd_string (self, buffer);
@@ -281,6 +285,7 @@ PPD_localizeIPPReason (PPD *self, PyObject *args, PyOb
ret = Py_None;
Py_INCREF (Py_None);
}
+#endif // __OpenBSD__
free (buffer);
return ret;
@@ -507,7 +512,7 @@ PPD_nondefaultsMarked (PPD *self)
return PyBool_FromLong (nondefaults_marked);
}