Date: Wednesday, August 13, 2014 @ 14:20:42
  Author: tpowa
Revision: 219662

upgpkg: dirmngr 1.1.1-3

fix segfaulting #38560

Added:
  dirmngr/trunk/dirmngr-pth-fix.patch
Modified:
  dirmngr/trunk/PKGBUILD

-----------------------+
 PKGBUILD              |   13 ++++++++++---
 dirmngr-pth-fix.patch |   17 +++++++++++++++++
 2 files changed, 27 insertions(+), 3 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD    2014-08-13 10:26:45 UTC (rev 219661)
+++ PKGBUILD    2014-08-13 12:20:42 UTC (rev 219662)
@@ -3,16 +3,23 @@
 
 pkgname=dirmngr
 pkgver=1.1.1
-pkgrel=2
+pkgrel=3
 pkgdesc="A daemon to handle CRL and certificate requests"
 arch=('i686' 'x86_64')
 license=('GPL')
 url="ftp://ftp.gnupg.org/gcrypt/dirmngr";
 depends=('libgcrypt' 'libldap' 'libksba' 'libgpg-error' 'libassuan' 'pth')
-source=(ftp://ftp.gnupg.org/gcrypt/$pkgname/$pkgname-$pkgver.tar.bz2)
+source=(ftp://ftp.gnupg.org/gcrypt/$pkgname/$pkgname-$pkgver.tar.bz2
+        'dirmngr-pth-fix.patch')
 install=dirmngr.install
-md5sums=('f5a40e93bcf07a94522579bfd58a2c96')
+md5sums=('f5a40e93bcf07a94522579bfd58a2c96'
+         '3592d141e818c0fbc71018e9ffc71953')
 
+prepare() {
+  cd $srcdir/$pkgname-$pkgver
+  patch -Np0 -i $srcdir/dirmngr-pth-fix.patch
+}
+
 build() {
   cd $srcdir/$pkgname-$pkgver
   # FIX for https://bugzilla.redhat.com/565131

Added: dirmngr-pth-fix.patch
===================================================================
--- dirmngr-pth-fix.patch                               (rev 0)
+++ dirmngr-pth-fix.patch       2014-08-13 12:20:42 UTC (rev 219662)
@@ -0,0 +1,17 @@
+Index: src/dirmngr.c
+===================================================================
+--- src/dirmngr.c      (revision 348)
++++ src/dirmngr.c      (working copy)
+@@ -665,8 +665,11 @@
+      the option parsing may need services of the libraries. */
+ 
+   /* Libgcrypt requires us to register the threading model first.
+-     Note that this will also do the pth_init. */
++     Note that this will also do the pth_init for libgcrypt < 1.6 */
+ 
++#if GCRYPT_VERSION_NUMBER >= 0x010600
++  pth_init ();
++#endif
+   /* Init Libgcrypt. */
+   rc = gcry_control (GCRYCTL_SET_THREAD_CBS, &gcry_threads_pth);
+   if (rc)

Reply via email to