changeset 3267:cce4bedf4c3d

new version of gnutls
author John W. Eaton <jwe@octave.org>
date Wed, 16 Oct 2013 23:45:07 -0400
parents 7dc2cc238ccc
children d7805a58c442
files index.html src/gnutls-1-fixes.patch src/gnutls-2-ldadd.patch src/gnutls.mk
diffstat 4 files changed, 157 insertions(+), 101 deletions(-) [+]
line wrap: on
line diff
--- a/index.html	Wed Oct 16 22:59:06 2013 -0400
+++ b/index.html	Wed Oct 16 23:45:07 2013 -0400
@@ -1293,7 +1293,7 @@
     </tr>
     <tr>
         <td id="gnutls-package">gnutls</td>
-        <td id="gnutls-version">3.1.4</td>
+        <td id="gnutls-version">3.2.3</td>
         <td id="gnutls-website"><a href="http://www.gnu.org/software/gnutls/">GnuTLS</a></td>
     </tr>
     <tr>
--- a/src/gnutls-1-fixes.patch	Wed Oct 16 22:59:06 2013 -0400
+++ b/src/gnutls-1-fixes.patch	Wed Oct 16 23:45:07 2013 -0400
@@ -1,143 +1,95 @@
 This file is part of MXE.
 See index.html for further information.
 
-Contains ad hoc patches for cross building.
-
-From de80b70d5d0e687d9c07f5ca270bb2ceb93d4dfa Mon Sep 17 00:00:00 2001
-From: Mark Brand <mabrand@mabrand.nl>
-Date: Fri, 28 Oct 2011 09:23:41 +0200
-Subject: [PATCH 1/6] add missing static library linking
-
-
-diff --git a/lib/gnutls.pc.in b/lib/gnutls.pc.in
-index c45f8f3..57d0dbb 100644
---- a/lib/gnutls.pc.in
-+++ b/lib/gnutls.pc.in
-@@ -19,6 +19,6 @@ Description: Transport Security Layer implementation for the GNU system
- URL: http://www.gnu.org/software/gnutls/
- Version: @VERSION@
- Libs: -L${libdir} -lgnutls
--Libs.private: @LTLIBNETTLE@
-+Libs.private: @LTLIBNETTLE@ @LIBS@
- @GNUTLS_REQUIRES_PRIVATE@
- Cflags: -I${includedir}
--- 
-1.7.10.4
-
-
-From 69da51d8c6b8720503a8b6220baf6a653d3e77b0 Mon Sep 17 00:00:00 2001
-From: Mark Brand <mabrand@mabrand.nl>
-Date: Thu, 24 Nov 2011 15:06:06 +0100
-Subject: [PATCH 2/6] disable doc and test (mingw-cross-env specific)
-
-
-diff --git a/Makefile.am b/Makefile.am
-index 74208b1..c46e900 100644
---- a/Makefile.am
-+++ b/Makefile.am
-@@ -23,7 +23,7 @@ DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc --disable-valgrind-tests
- 
- SUBDIRS = gl lib extra libdane po
- 
--SUBDIRS += src doc tests
-+SUBDIRS += src
- 
- if HAVE_GUILE
- SUBDIRS += guile
--- 
-1.7.10.4
-
-
-From 50868df9034b6e8ad459363edaca1436794e7212 Mon Sep 17 00:00:00 2001
+From 05cd16c35674665009d16f2469b9124c16638237 Mon Sep 17 00:00:00 2001
 From: Mark Brand <mabrand@mabrand.nl>
 Date: Tue, 3 Apr 2012 13:58:42 +0200
-Subject: [PATCH 3/6] Revert "make dist will also make lzip compressed
- tarball"
+Subject: [PATCH 1/4] Revert "make dist will also make lzip compressed tarball"
 
 This reverts commit 97ac1bc58274f651338444693bd75441ba12f46f.
 
 diff --git a/configure.ac b/configure.ac
-index 8d337ee..8c0a76e 100644
+index 6459403..f8dd727 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -25,7 +25,7 @@ AC_INIT([GnuTLS], [3.1.3], [bug-gnutls@gnu.org])
- AC_CONFIG_AUX_DIR([build-aux])
+@@ -26,7 +26,7 @@ AC_CONFIG_AUX_DIR([build-aux])
  AC_CONFIG_MACRO_DIR([m4])
+ AC_CANONICAL_HOST
  
--AM_INIT_AUTOMAKE([1.11.3 no-dist-gzip dist-xz dist-lzip -Wall -Werror -Wno-override])
-+AM_INIT_AUTOMAKE([1.11.3 no-dist-gzip dist-xz -Wall -Werror -Wno-override])
+-AM_INIT_AUTOMAKE([1.12.2 no-dist-gzip dist-xz dist-lzip -Wall -Wno-override])
++AM_INIT_AUTOMAKE([1.12.2 no-dist-gzip dist-xz -Wall -Wno-override])
  m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
- AM_CONFIG_HEADER(config.h)
+ AC_CONFIG_HEADERS([config.h])
  
 -- 
-1.7.10.4
+1.8.1.4
 
 
-From 613dff6244621ad8eef5afdf38edc16f90a275a4 Mon Sep 17 00:00:00 2001
+From 6d7644c82de49b38afda2a171d1195861ebd9db0 Mon Sep 17 00:00:00 2001
 From: Mark Brand <mabrand@mabrand.nl>
 Date: Wed, 6 Jun 2012 09:57:24 +0200
-Subject: [PATCH 4/6] AM_PROG_AR for automake 1.12 compatibility
+Subject: [PATCH 2/4] AM_PROG_AR for automake 1.12 compatibility
 
 Taken from
 http://lists.gnu.org/archive/html/automake/2012-05/msg00014.html
 
 diff --git a/configure.ac b/configure.ac
-index 8c0a76e..14e6da2 100644
+index f8dd727..2c05458 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -37,6 +37,7 @@ dnl Checks for programs.
- AC_PROG_CC
+@@ -40,6 +40,7 @@ gl_EARLY
  AM_PROG_AS
+ AM_PROG_AR
  AC_PROG_CXX
 +m4_ifdef([AM_PROG_AR], [AM_PROG_AR])
- gl_EARLY
  
  # For includes/gnutls/gnutls.h.in.
+ AC_SUBST(MAJOR_VERSION, `echo $PACKAGE_VERSION | sed 's/\(.*\)\..*\..*/\1/g'`)
 -- 
-1.7.10.4
+1.8.1.4
+
+
+From 7afa4d386bb2076890113a5d4e665c39583ff025 Mon Sep 17 00:00:00 2001
+From: Mark Brand <mabrand@mabrand.nl>
+Date: Mon, 4 Feb 2013 16:11:12 +0100
+Subject: [PATCH 3/4] add missing private lib to pc file
 
 
-From 37a6a85032d3ef7bb4ec05c106da01b2354778f4 Mon Sep 17 00:00:00 2001
-From: Mark Brand <mabrand@mabrand.nl>
-Date: Thu, 16 Aug 2012 11:13:47 +0200
-Subject: [PATCH 5/6] allow automake warnings not to be errors
+diff --git a/lib/gnutls.pc.in b/lib/gnutls.pc.in
+index a25fcdf..3860c68 100644
+--- a/lib/gnutls.pc.in
++++ b/lib/gnutls.pc.in
+@@ -19,6 +19,6 @@ Description: Transport Security Layer implementation for the GNU system
+ URL: http://www.gnutls.org/
+ Version: @VERSION@
+ Libs: -L${libdir} -lgnutls
+-Libs.private: @LTLIBZ@ @LTLIBINTL@ @LIBSOCKET@ @LTLIBPTHREAD@ @LTLIBICONV@ @P11_KIT_LIBS@ @LIB_SELECT@ @TSS_LIBS@ @GMP_LIBS@
++Libs.private: @LTLIBZ@ @LTLIBINTL@ @LIBSOCKET@ @LTLIBPTHREAD@ @LTLIBICONV@ @P11_KIT_LIBS@ @LIB_SELECT@ @TSS_LIBS@ @GMP_LIBS@ -lcrypt32
+ @GNUTLS_REQUIRES_PRIVATE@
+ Cflags: -I${includedir}
+-- 
+1.8.1.4
+
+
+From 903e858e59718f03fd3b3bef00fab897b0313007 Mon Sep 17 00:00:00 2001
+From: Tony Theodore <tonyt@logyst.com>
+Date: Wed, 6 Feb 2013 08:43:43 +0100
+Subject: [PATCH 4/4] relax automake version check
 
 
 diff --git a/configure.ac b/configure.ac
-index 14e6da2..0e427ce 100644
+index 2c05458..dd45228 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -25,7 +25,7 @@ AC_INIT([GnuTLS], [3.1.3], [bug-gnutls@gnu.org])
- AC_CONFIG_AUX_DIR([build-aux])
+@@ -26,7 +26,7 @@ AC_CONFIG_AUX_DIR([build-aux])
  AC_CONFIG_MACRO_DIR([m4])
+ AC_CANONICAL_HOST
  
--AM_INIT_AUTOMAKE([1.11.3 no-dist-gzip dist-xz -Wall -Werror -Wno-override])
-+AM_INIT_AUTOMAKE([1.11.3 no-dist-gzip dist-xz -Wall -Wno-override])
+-AM_INIT_AUTOMAKE([1.12.2 no-dist-gzip dist-xz -Wall -Wno-override])
++AM_INIT_AUTOMAKE([1.11.1 no-dist-gzip dist-xz -Wall -Wno-override])
  m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
- AM_CONFIG_HEADER(config.h)
+ AC_CONFIG_HEADERS([config.h])
  
 -- 
-1.7.10.4
-
-
-From a1907c3679fc845ac5b241d25c86fb1106f63f84 Mon Sep 17 00:00:00 2001
-From: Mark Brand <mabrand@mabrand.nl>
-Date: Thu, 20 Sep 2012 12:59:19 +0200
-Subject: [PATCH 6/6] add missing libs to Libs.private
-
+1.8.1.4
 
-diff --git a/lib/gnutls.pc.in b/lib/gnutls.pc.in
-index 57d0dbb..02a6ef7 100644
---- a/lib/gnutls.pc.in
-+++ b/lib/gnutls.pc.in
-@@ -19,6 +19,6 @@ Description: Transport Security Layer implementation for the GNU system
- URL: http://www.gnu.org/software/gnutls/
- Version: @VERSION@
- Libs: -L${libdir} -lgnutls
--Libs.private: @LTLIBNETTLE@ @LIBS@
-+Libs.private: @LTLIBNETTLE@ @LIBS@ -lcrypt32 -lws2_32
- @GNUTLS_REQUIRES_PRIVATE@
- Cflags: -I${includedir}
--- 
-1.7.10.4
-
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/gnutls-2-ldadd.patch	Wed Oct 16 23:45:07 2013 -0400
@@ -0,0 +1,93 @@
+diff -ur a/src/Makefile.am b/src/Makefile.am
+--- a/src/Makefile.am	2013-03-03 04:04:09.000000000 -0500
++++ b/src/Makefile.am	2013-10-16 23:34:43.999201873 -0400
+@@ -67,7 +67,7 @@
+ if ENABLE_SRP
+ srptool_SOURCES = srptool.c
+ srptool_LDADD = ../lib/libgnutls.la libcmd-srp.la ../gl/libgnu.la 
+-srptool_LDADD += $(LIBOPTS_LDADD) $(LTLIBINTL)
++srptool_LDADD += $(LIBOPTS_LDADD) ../gl/libgnu.la $(LTLIBINTL)
+ noinst_LTLIBRARIES += libcmd-srp.la
+ libcmd_srp_la_CFLAGS =
+ libcmd_srp_la_SOURCES = srptool-args.def srptool-args.c srptool-args.h
+@@ -75,7 +75,7 @@
+ 
+ psktool_SOURCES = psk.c
+ psktool_LDADD = ../lib/libgnutls.la libcmd-psk.la ../gl/libgnu.la 
+-psktool_LDADD += $(LIBOPTS_LDADD) $(LTLIBINTL)
++psktool_LDADD += $(LIBOPTS_LDADD) ../gl/libgnu.la $(LTLIBINTL)
+ noinst_LTLIBRARIES += libcmd-psk.la
+ libcmd_psk_la_CFLAGS = 
+ libcmd_psk_la_SOURCES = psk-args.def psk-args.c psk-args.h
+@@ -86,7 +86,7 @@
+ ocsptool_SOURCES = ocsptool.c ocsptool-common.h ocsptool-common.c \
+ 	socket.c socket.h
+ ocsptool_LDADD = ../lib/libgnutls.la libcmd-ocsp.la ../gl/libgnu.la 
+-ocsptool_LDADD += $(LIBOPTS_LDADD) $(LTLIBINTL) $(GETADDRINFO_LIB)
++ocsptool_LDADD += $(LIBOPTS_LDADD) ../gl/libgnu.la $(LTLIBINTL) $(GETADDRINFO_LIB)
+ noinst_LTLIBRARIES += libcmd-ocsp.la
+ libcmd_ocsp_la_CFLAGS =
+ libcmd_ocsp_la_SOURCES = ocsptool-args.def ocsptool-args.h ocsptool-args.c
+@@ -99,7 +99,7 @@
+   certtool-common.h 
+ gnutls_serv_LDADD = ../lib/libgnutls.la
+ gnutls_serv_LDADD += libcmd-serv.la ../gl/libgnu.la
+-gnutls_serv_LDADD += $(LIBOPTS_LDADD) $(LTLIBINTL)
++gnutls_serv_LDADD += $(LIBOPTS_LDADD) ../gl/libgnu.la $(LTLIBINTL)
+ gnutls_serv_LDADD += $(LIBSOCKET) $(GETADDRINFO_LIB)
+ noinst_LTLIBRARIES += libcmd-serv.la
+ libcmd_serv_la_CFLAGS =
+@@ -116,7 +116,7 @@
+ if ENABLE_DANE
+ gnutls_cli_LDADD += ../libdane/libgnutls-dane.la
+ endif
+-gnutls_cli_LDADD += libcmd-cli.la ../gl/libgnu.la $(LIBOPTS_LDADD) $(LTLIBINTL)
++gnutls_cli_LDADD += libcmd-cli.la ../gl/libgnu.la $(LIBOPTS_LDADD) ../gl/libgnu.la $(LTLIBINTL)
+ gnutls_cli_LDADD += $(LIBSOCKET) $(GETADDRINFO_LIB) $(LIB_CLOCK_GETTIME) \
+ 	 $(SERVENT_LIB)
+ noinst_LTLIBRARIES += libcmd-cli.la
+@@ -129,7 +129,7 @@
+ 		socket.c socket.h common.h common.c
+ gnutls_cli_debug_LDADD = ../lib/libgnutls.la libcmd-cli-debug.la 
+ gnutls_cli_debug_LDADD += ../gl/libgnu.la
+-gnutls_cli_debug_LDADD += $(LIBOPTS_LDADD) $(LTLIBINTL)
++gnutls_cli_debug_LDADD += $(LIBOPTS_LDADD) ../gl/libgnu.la $(LTLIBINTL)
+ gnutls_cli_debug_LDADD += $(LIBSOCKET) $(GETADDRINFO_LIB)
+ noinst_LTLIBRARIES += libcmd-cli-debug.la
+ libcmd_cli_debug_la_CFLAGS =
+@@ -146,7 +146,7 @@
+ libcmd_certtool_la_SOURCES = certtool-args.c certtool-args.def certtool-args.h	\
+ 	certtool-cfg.h certtool-cfg.c
+ libcmd_certtool_la_LIBADD = ../gl/libgnu.la ../lib/libgnutls.la
+-libcmd_certtool_la_LIBADD += $(LIBOPTS_LDADD) $(LTLIBINTL)
++libcmd_certtool_la_LIBADD += $(LIBOPTS_LDADD) ../gl/libgnu.la $(LTLIBINTL)
+ libcmd_certtool_la_LIBADD += $(LTLIBREADLINE)
+ libcmd_certtool_la_LIBADD += $(INET_PTON_LIB)
+ 
+@@ -162,7 +162,7 @@
+ libcmd_danetool_la_SOURCES = danetool-args.c danetool-args.def danetool-args.h \
+ 	certtool-cfg.h certtool-cfg.c
+ libcmd_danetool_la_LIBADD = ../gl/libgnu.la ../lib/libgnutls.la
+-libcmd_danetool_la_LIBADD += $(LIBOPTS_LDADD) $(LTLIBINTL)
++libcmd_danetool_la_LIBADD += $(LIBOPTS_LDADD) ../gl/libgnu.la $(LTLIBINTL)
+ libcmd_danetool_la_LIBADD += $(LTLIBREADLINE)
+ libcmd_danetool_la_LIBADD += $(INET_PTON_LIB)
+ 
+@@ -173,7 +173,7 @@
+ 	certtool-extras.c p11tool.h common.c
+ p11tool_LDADD = ../lib/libgnutls.la
+ p11tool_LDADD += libcmd-p11tool.la ../gl/libgnu.la
+-p11tool_LDADD += $(LIBOPTS_LDADD) $(LTLIBINTL)
++p11tool_LDADD += $(LIBOPTS_LDADD) ../gl/libgnu.la $(LTLIBINTL)
+ 
+ noinst_LTLIBRARIES += libcmd-p11tool.la
+ libcmd_p11tool_la_CFLAGS =
+@@ -189,7 +189,7 @@
+ tpmtool_SOURCES = tpmtool-args.def tpmtool.c certtool-common.c certtool-extras.c common.c
+ tpmtool_LDADD = ../lib/libgnutls.la
+ tpmtool_LDADD += libcmd-tpmtool.la ../gl/libgnu.la
+-tpmtool_LDADD += $(LIBOPTS_LDADD) $(LTLIBINTL)
++tpmtool_LDADD += $(LIBOPTS_LDADD) ../gl/libgnu.la $(LTLIBINTL)
+ 
+ noinst_LTLIBRARIES += libcmd-tpmtool.la
+ libcmd_tpmtool_la_CFLAGS =
--- a/src/gnutls.mk	Wed Oct 16 22:59:06 2013 -0400
+++ b/src/gnutls.mk	Wed Oct 16 23:45:07 2013 -0400
@@ -2,11 +2,11 @@
 # See index.html for further information.
 
 PKG             := gnutls
-$(PKG)_CHECKSUM := d3531761f2754e81f72428d482c0689f0a5e064f
+$(PKG)_CHECKSUM := 18f5fffd1a0384944cb76cbedc0720c4726470f4
 $(PKG)_SUBDIR   := gnutls-$($(PKG)_VERSION)
 $(PKG)_FILE     := gnutls-$($(PKG)_VERSION).tar.xz
 $(PKG)_URL      := http://ftp.gnu.org/gnu/gnutls/$($(PKG)_FILE)
-$(PKG)_DEPS     := nettle zlib
+$(PKG)_DEPS     := gettext nettle pcre zlib
 
 define $(PKG)_UPDATE
     $(WGET) -q -O- 'http://git.savannah.gnu.org/gitweb/?p=gnutls.git;a=tags' | \
@@ -22,6 +22,9 @@
     cd '$(1)' && aclocal -I m4 -I gl/m4 -I src/libopts/m4 --install
     cd '$(1)' && autoconf
     cd '$(1)' && automake --add-missing
+    if [ "$(MXE_NATIVE_BUILD)" = no ]; then \
+      $(SED) -i 's/libopts_cv_with_libregex=no/libopts_cv_with_libregex=yes/g;' '$(1)/configure'; \
+    fi
     # AI_ADDRCONFIG referenced by src/serv.c but not provided by mingw.
     # Value taken from http://msdn.microsoft.com/en-us/library/windows/desktop/ms737530%28v=vs.85%29.aspx
     cd '$(1)' && ./configure \
@@ -31,10 +34,18 @@
         --prefix='$(HOST_PREFIX)' \
         --disable-nls \
         --disable-guile \
+        --disable-doc \
         --with-included-libtasn1 \
+        --with-libregex='$(HOST_PREFIX)' \
+        --with-regex-header=pcreposix.h \
+        --with-libregex-cflags="`'$(TARGET)-pkg-config' libpcreposix --cflags`" \
+        --with-libregex-libs="`'$(TARGET)-pkg-config' libpcreposix --libs`" \
         --with-included-libcfg \
         --without-p11-kit \
-        --disable-silent-rules && $(CONFIGURE_POST_HOOK)
+        --disable-silent-rules \
+        CPPFLAGS='-DWINVER=0x0501 -DAI_ADDRCONFIG=0x0400 -DIPV6_V6ONLY=27' \
+        LIBS='-lws2_32' \
+        ac_cv_prog_AR='$(TARGET)-ar' && $(CONFIGURE_POST_HOOK)
 
     $(MAKE) -C '$(1)' -j '$(JOBS)' install
 endef