[packages] gnupg: update to 1.4.11
authorStephen Walker <stephendwalker@gmail.com>
Sat, 1 Jan 2011 06:59:53 +0000 (06:59 +0000)
committerStephen Walker <stephendwalker@gmail.com>
Sat, 1 Jan 2011 06:59:53 +0000 (06:59 +0000)
 * update patch to include the post release fixes
 * use PKG_INSTALL

SVN-Revision: 24862

utils/gnupg/Makefile
utils/gnupg/patches/001-mips_gcc4.4.patch

index b64c08f..291a749 100644 (file)
@@ -1,5 +1,5 @@
 #
-# Copyright (C) 2006-2009 OpenWrt.org
+# Copyright (C) 2006-2011 OpenWrt.org
 #
 # This is free software, licensed under the GNU General Public License v2.
 # See /LICENSE for more information.
@@ -8,13 +8,15 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=gnupg
-PKG_VERSION:=1.4.10
+PKG_VERSION:=1.4.11
 PKG_RELEASE:=1
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
 PKG_SOURCE_URL:=ftp://ftp.franken.de/pub/crypt/mirror/ftp.gnupg.org/gcrypt/gnupg \
        ftp://ftp.gnupg.org/gcrypt/gnupg
-PKG_MD5SUM:=dcf7ed712997888d616e029637bfc303
+PKG_MD5SUM:=411744e1ef8ce90b87938c4203f001f1
+
+PKG_INSTALL:=1
 
 include $(INCLUDE_DIR)/package.mk
 
@@ -57,7 +59,7 @@ MAKE_FLAGS += \
 
 define Package/gnupg/install
        $(INSTALL_DIR) $(1)/usr/bin
-       $(INSTALL_BIN) $(PKG_BUILD_DIR)/g10/gpg $(1)/usr/bin/
+       $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gpg $(1)/usr/bin/
 endef
 
 $(eval $(call BuildPackage,gnupg))
index b101a5b..bcc847c 100644 (file)
@@ -1,42 +1,86 @@
-Index: gnupg-1.4.10/mpi/longlong.h
-===================================================================
---- gnupg-1.4.10.orig/mpi/longlong.h   2008-12-11 17:39:43.000000000 +0100
-+++ gnupg-1.4.10/mpi/longlong.h        2010-03-27 14:27:53.000000000 +0100
-@@ -706,18 +706,35 @@
- #endif /* __m88110__ */
- #endif /* __m88000__ */
-+/* Test for gcc >= maj.min, as per __GNUC_PREREQ in glibc */
-+#if defined (__GNUC__) && defined (__GNUC_MINOR__)
-+#define __GNUC_PREREQ(maj, min) \
-+      ((__GNUC__ << 16) + __GNUC_MINOR__ >= ((maj) << 16) + (min))
-+#else
-+#define __GNUC_PREREQ(maj, min)  0
-+#endif
-+
- /***************************************
+--- a/mpi/longlong.h
++++ b/mpi/longlong.h
+@@ -710,12 +710,13 @@ extern USItype __udiv_qrnnd ();
   **************  MIPS  *****************
   ***************************************/
  #if defined (__mips__) && W_TYPE_SIZE == 32
--#if __GNUC__ > 2 || __GNUC_MINOR__ >= 7
-+#if __GNUC_PREREQ (4,4)
+-#if __GNUC__ > 4 || ( __GNUC__ == 4 && __GNUC_MINOR >= 4 )
+-#define umul_ppmm(w1, w0, u, v)                                         \
++#if (__GNUC__ >= 5) || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4)
 +#define umul_ppmm(w1, w0, u, v) \
-+  do {                                                                 \
-+      UDItype __ll = (UDItype)(u) * (v);                                 \
-+      w1 = __ll >> 32;                                                   \
-+      w0 = __ll;                                                         \
-+  } while (0)
-+#endif
-+#if !defined (umul_ppmm) && __GNUC_PREREQ (2,7)
+   do {                                                                  \
+-    UDItype __ll = (UDItype)(u) * (v);                                  \
+-    w1 = __ll >> 32;                                                    \
+-    w0 = __ll;                                                          \
++    UDItype _r;                                                         \
++    _r = (UDItype) u * v;                                               \
++    (w1) = _r >> 32;                                                    \
++    (w0) = (USItype) _r;                                                \
+   } while (0)
+ #elif __GNUC__ > 2 || __GNUC_MINOR__ >= 7
+ #define umul_ppmm(w1, w0, u, v)                                         \
+@@ -727,8 +728,8 @@ extern USItype __udiv_qrnnd ();
+ #else
  #define umul_ppmm(w1, w0, u, v) \
-   __asm__ ("multu %2,%3"                                                \
-          : "=l" ((USItype)(w0)),                                      \
-            "=h" ((USItype)(w1))                                       \
+   __asm__ ("multu %2,%3 \n" \
+-         "mflo %0 \n"     \
+-         "mfhi %1"                                                        \
++         "mflo %0 \n"                                                 \
++         "mfhi %1"                                                    \
+          : "=d" ((USItype)(w0)),                                      \
+            "=d" ((USItype)(w1))                                       \
           : "d" ((USItype)(u)),                                        \
-            "d" ((USItype)(v)))
+@@ -742,25 +743,34 @@ extern USItype __udiv_qrnnd ();
+  **************  MIPS/64  **************
+  ***************************************/
+ #if (defined (__mips) && __mips >= 3) && W_TYPE_SIZE == 64
+-#if __GNUC__ > 2 || __GNUC_MINOR__ >= 7
+-#define umul_ppmm(w1, w0, u, v) \
+-  __asm__ ("dmultu %2,%3"                                               \
+-         : "=l" ((UDItype)(w0)),                                      \
+-           "=h" ((UDItype)(w1))                                       \
+-         : "d" ((UDItype)(u)),                                        \
+-           "d" ((UDItype)(v)))
 -#else
-+#endif
-+#if !defined (umul_ppmm)
- #define umul_ppmm(w1, w0, u, v) \
-   __asm__ ("multu %2,%3 \n" \
-          "mflo %0 \n"     \
+-#define umul_ppmm(w1, w0, u, v) \
+-  __asm__ ("dmultu %2,%3 \n"    \
+-         "mflo %0 \n"         \
+-         "mfhi %1"                                                        \
+-         : "=d" ((UDItype)(w0)),                                      \
+-           "=d" ((UDItype)(w1))                                       \
+-         : "d" ((UDItype)(u)),                                        \
+-           "d" ((UDItype)(v)))
+-#endif
+-#define UMUL_TIME 20
+-#define UDIV_TIME 140
++# if (__GNUC__ >= 5) || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4)
++   typedef unsigned int UTItype __attribute__ ((mode (TI)));
++#  define umul_ppmm(w1, w0, u, v)                                       \
++  do {                                                                  \
++    UTItype _r;                                                         \
++    _r = (UTItype) u * v;                                               \
++    (w1) = _r >> 64;                                                    \
++    (w0) = (UDItype) _r;                                                \
++  } while (0)
++# elif if __GNUC__ > 2 || __GNUC_MINOR__ >= 7
++#  define umul_ppmm(w1, w0, u, v)                                       \
++     __asm__ ("dmultu %2,%3"                                            \
++              : "=l" ((UDItype)(w0)),                                   \
++                "=h" ((UDItype)(w1))                                    \
++              : "d" ((UDItype)(u)),                                     \
++                "d" ((UDItype)(v)))
++# else
++#  define umul_ppmm(w1, w0, u, v) \
++     __asm__ ("dmultu %2,%3 \n"    \
++              "mflo %0 \n"                                              \
++              "mfhi %1"                                                 \
++              : "=d" ((UDItype)(w0)),                                   \
++              "=d" ((UDItype)(w1))                                      \
++              : "d" ((UDItype)(u)),                                     \
++              "d" ((UDItype)(v)))
++# endif
++# define UMUL_TIME 20
++# define UDIV_TIME 140
+ #endif /* __mips__ */