rpms/cups/devel cups-gnutls-gcrypt-threads.patch, 1.1, 1.2 cups.spec, 1.580, 1.581
Jiří Popelka
jpopelka at fedoraproject.org
Mon Feb 15 11:40:21 UTC 2010
Author: jpopelka
Update of /cvs/pkgs/rpms/cups/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv1791
Modified Files:
cups-gnutls-gcrypt-threads.patch cups.spec
Log Message:
* Mon Feb 15 2010 Jiri Popelka <jpopelka at redhat.com> 1:1.4.2-29
- Improve cups-gnutls-gcrypt-threads.patch (#564841, STR #3461).
cups-gnutls-gcrypt-threads.patch:
config-scripts/cups-ssl.m4 | 2 +-
cups/http-private.h | 2 ++
cups/http.c | 7 +++++++
scheduler/server.c | 7 ++++++-
4 files changed, 16 insertions(+), 2 deletions(-)
Index: cups-gnutls-gcrypt-threads.patch
===================================================================
RCS file: /cvs/pkgs/rpms/cups/devel/cups-gnutls-gcrypt-threads.patch,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -p -r1.1 -r1.2
--- cups-gnutls-gcrypt-threads.patch 21 Dec 2009 17:11:57 -0000 1.1
+++ cups-gnutls-gcrypt-threads.patch 15 Feb 2010 11:40:21 -0000 1.2
@@ -1,17 +1,32 @@
+diff -up cups-1.4.2/config-scripts/cups-ssl.m4.gnutls-gcrypt-threads cups-1.4.2/config-scripts/cups-ssl.m4
+--- cups-1.4.2/config-scripts/cups-ssl.m4.gnutls-gcrypt-threads 2010-02-15 12:21:32.000000000 +0100
++++ cups-1.4.2/config-scripts/cups-ssl.m4 2010-02-15 12:24:57.000000000 +0100
+@@ -61,7 +61,7 @@ if test x$enable_ssl != xno; then
+ if test "x${SSLLIBS}" = "x" -a "x${enable_gnutls}" != "xno" -a "x$PKGCONFIG" != x; then
+ AC_PATH_PROG(LIBGNUTLSCONFIG,libgnutls-config)
+ if $PKGCONFIG --exists gnutls; then
+- SSLLIBS=`$PKGCONFIG --libs gnutls`
++ SSLLIBS="`$PKGCONFIG --libs gnutls` -lgcrypt"
+ SSLFLAGS=`$PKGCONFIG --cflags gnutls`
+ AC_DEFINE(HAVE_SSL)
+ AC_DEFINE(HAVE_GNUTLS)
diff -up cups-1.4.2/cups/http.c.gnutls-gcrypt-threads cups-1.4.2/cups/http.c
---- cups-1.4.2/cups/http.c.gnutls-gcrypt-threads 2009-12-21 16:50:58.931552118 +0000
-+++ cups-1.4.2/cups/http.c 2009-12-21 16:51:15.047552357 +0000
-@@ -1161,6 +1161,9 @@ httpHead(http_t *http, /* I - Conne
+--- cups-1.4.2/cups/http.c.gnutls-gcrypt-threads 2010-02-15 12:21:32.000000000 +0100
++++ cups-1.4.2/cups/http.c 2010-02-15 12:25:57.000000000 +0100
+@@ -1161,6 +1161,12 @@ httpHead(http_t *http, /* I - Conne
return (http_send(http, HTTP_HEAD, uri));
}
+#ifdef HAVE_GNUTLS
++/* We always have to initialize threading in gcrypt here in libcups
++ * even if cupsd is configured without threading, because an
++ * application using libcups may be using threads itself. */
+GCRY_THREAD_OPTION_PTHREAD_IMPL;
+#endif
/*
* 'httpInitialize()' - Initialize the HTTP interface library and set the
-@@ -1205,6 +1208,7 @@ httpInitialize(void)
+@@ -1205,6 +1211,7 @@ httpInitialize(void)
#endif /* WIN32 */
#ifdef HAVE_GNUTLS
@@ -20,8 +35,8 @@ diff -up cups-1.4.2/cups/http.c.gnutls-g
#endif /* HAVE_GNUTLS */
diff -up cups-1.4.2/cups/http-private.h.gnutls-gcrypt-threads cups-1.4.2/cups/http-private.h
---- cups-1.4.2/cups/http-private.h.gnutls-gcrypt-threads 2009-04-07 16:48:14.000000000 +0100
-+++ cups-1.4.2/cups/http-private.h 2009-12-21 16:51:15.049552624 +0000
+--- cups-1.4.2/cups/http-private.h.gnutls-gcrypt-threads 2009-04-07 17:48:14.000000000 +0200
++++ cups-1.4.2/cups/http-private.h 2010-02-15 12:26:30.000000000 +0100
@@ -98,6 +98,8 @@ extern BIO_METHOD *_httpBIOMethods(void)
* The GNU TLS library is more of a "bare metal" SSL/TLS library...
*/
@@ -32,25 +47,26 @@ diff -up cups-1.4.2/cups/http-private.h.
typedef struct
{
diff -up cups-1.4.2/scheduler/server.c.gnutls-gcrypt-threads cups-1.4.2/scheduler/server.c
---- cups-1.4.2/scheduler/server.c.gnutls-gcrypt-threads 2008-09-10 23:05:29.000000000 +0100
-+++ cups-1.4.2/scheduler/server.c 2009-12-21 16:51:15.048553044 +0000
-@@ -35,7 +35,9 @@
+--- cups-1.4.2/scheduler/server.c.gnutls-gcrypt-threads 2008-09-11 00:05:29.000000000 +0200
++++ cups-1.4.2/scheduler/server.c 2010-02-15 12:24:13.000000000 +0100
+@@ -35,6 +35,9 @@
*/
static int started = 0;
--
-+#if !defined(HAVE_LIBSSL) && defined(HAVE_GNUTLS)
++#if !defined(HAVE_LIBSSL) && defined(HAVE_GNUTLS) && defined(HAVE_PTHREAD_H)
+GCRY_THREAD_OPTION_PTHREAD_IMPL;
+#endif
+
/*
- * 'cupsdStartServer()' - Start the server.
-@@ -75,7 +77,7 @@ cupsdStartServer(void)
+@@ -75,7 +78,9 @@ cupsdStartServer(void)
/*
* Initialize the encryption libraries...
*/
-
++#ifdef HAVE_PTHREAD_H
+ gcry_control (GCRYCTL_SET_THREAD_CBS, &gcry_threads_pthread);
++#endif /* HAVE_PTHREAD_H */
gnutls_global_init();
#endif /* HAVE_LIBSSL */
Index: cups.spec
===================================================================
RCS file: /cvs/pkgs/rpms/cups/devel/cups.spec,v
retrieving revision 1.580
retrieving revision 1.581
diff -u -p -r1.580 -r1.581
--- cups.spec 4 Feb 2010 14:50:53 -0000 1.580
+++ cups.spec 15 Feb 2010 11:40:21 -0000 1.581
@@ -8,7 +8,7 @@
Summary: Common Unix Printing System
Name: cups
Version: 1.4.2
-Release: 28%{?dist}
+Release: 29%{?dist}
License: GPLv2
Group: System Environment/Daemons
Source: http://ftp.easysw.com/pub/cups/%{version}/cups-%{version}-source.tar.bz2
@@ -552,6 +552,9 @@ rm -rf $RPM_BUILD_ROOT
%{php_extdir}/phpcups.so
%changelog
+* Mon Feb 15 2010 Jiri Popelka <jpopelka at redhat.com> 1:1.4.2-29
+- Improve cups-gnutls-gcrypt-threads.patch (#564841, STR #3461).
+
* Thu Feb 4 2010 Tim Waugh <twaugh at redhat.com> - 1:1.4.2-28
- Rebuild for postscriptdriver tags.
More information about the scm-commits
mailing list