[vlc-commits] contrib: Bump gnutls to 3.6.6
Hugo Beauzée-Luyssen
git at videolan.org
Thu Feb 14 11:02:52 CET 2019
vlc | branch: master | Hugo Beauzée-Luyssen <hugo at beauzee.fr> | Wed Feb 13 14:42:39 2019 +0100| [6f2a105265fc9ddeb238f2b2f36f55e0481529c4] | committer: Hugo Beauzée-Luyssen
contrib: Bump gnutls to 3.6.6
And drop upstreamed or now unrequired patches
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=6f2a105265fc9ddeb238f2b2f36f55e0481529c4
---
contrib/src/gnutls/SHA512SUMS | 2 +-
contrib/src/gnutls/gnutls-libidn.patch | 36 ----------
contrib/src/gnutls/gnutls-loadlibrary.patch | 22 ------
contrib/src/gnutls/gnutls-pkgconfig-static.patch | 4 +-
contrib/src/gnutls/gnutls-win32.patch | 4 +-
contrib/src/gnutls/gnutls-winrt.patch | 41 -----------
contrib/src/gnutls/rules.mak | 11 +--
contrib/src/gnutls/winrt-topendir.patch | 86 ------------------------
8 files changed, 7 insertions(+), 199 deletions(-)
diff --git a/contrib/src/gnutls/SHA512SUMS b/contrib/src/gnutls/SHA512SUMS
index cfaf497037..e867f5235a 100644
--- a/contrib/src/gnutls/SHA512SUMS
+++ b/contrib/src/gnutls/SHA512SUMS
@@ -1 +1 @@
-a78a59505e59c62ca671b34eacaeadcf070a943b12d964b7362962ba05636136638063491c37bb1883807014b8b6cf4f83f7d5b918ed02d5fbb52155679ce52f gnutls-3.5.19.tar.xz
+4ff34f38d7dc543bc5750d8fdfe9be84af60c66e8d41da45f6cffc11d6c6c726784fd2d471b3416604ca1f3f9efb22ff7a290d5c92c96deda38df6ae3e794cc1 gnutls-3.6.6.tar.xz
diff --git a/contrib/src/gnutls/gnutls-libidn.patch b/contrib/src/gnutls/gnutls-libidn.patch
deleted file mode 100644
index 5f00fa6457..0000000000
--- a/contrib/src/gnutls/gnutls-libidn.patch
+++ /dev/null
@@ -1,36 +0,0 @@
---- gnutls/lib/x509/Makefile.am.ORIG Tue Jul 21 05:42:08 2015
-+++ gnutls/lib/x509/Makefile.am Wed Jun 29 15:05:35 2016
-@@ -23,7 +23,8 @@
- -I$(srcdir)/../includes \
- -I$(builddir)/../includes \
- -I$(srcdir)/.. \
-- $(LIBOPENCDK_CFLAGS)
-+ $(LIBOPENCDK_CFLAGS) \
-+ $(LIBIDN_CFLAGS)
-
- if ENABLE_MINITASN1
- AM_CPPFLAGS += -I$(srcdir)/../minitasn1
---- gnutls/lib/ext/Makefile.am.ORIG Wed Feb 4 23:35:05 2015
-+++ gnutls/lib/ext/Makefile.am Wed Jun 29 15:19:34 2016
-@@ -26,7 +26,8 @@
- -I$(builddir)/../includes \
- -I$(builddir)/../../gl \
- -I$(srcdir)/.. \
-- -I$(srcdir)/../opencdk
-+ -I$(srcdir)/../opencdk \
-+ $(LIBIDN_CFLAGS)
-
- if ENABLE_MINITASN1
- AM_CPPFLAGS += -I$(srcdir)/../minitasn1
---- gnutls/src/Makefile.am.ORIG Fri Jan 8 04:10:34 2016
-+++ gnutls/src/Makefile.am Wed Jun 29 15:20:12 2016
-@@ -41,7 +41,8 @@
- -I$(srcdir)/../lib/includes \
- -I$(srcdir)/../libdane/includes \
- -I$(srcdir)/../extra/includes \
-- $(LIBOPTS_CFLAGS)
-+ $(LIBOPTS_CFLAGS) \
-+ $(LIBIDN_CFLAGS)
-
- if NEED_LIBOPTS
- LIBOPTS = libopts/libopts.la
diff --git a/contrib/src/gnutls/gnutls-loadlibrary.patch b/contrib/src/gnutls/gnutls-loadlibrary.patch
deleted file mode 100644
index 84a3230074..0000000000
--- a/contrib/src/gnutls/gnutls-loadlibrary.patch
+++ /dev/null
@@ -1,22 +0,0 @@
---- gnutls-3.5.16/lib/system/keys-win.c 2016-11-05 19:12:02.000000000 +0100
-+++ gnutls-3.5.16/lib/system/keys-win.c.new 2017-12-26 16:29:00.221119300 +0100
-@@ -1426,7 +1426,7 @@
- int ret;
-
- #ifdef DYN_NCRYPT
-- ncrypt_lib = LoadLibraryA("ncrypt.dll");
-+ ncrypt_lib = LoadLibrary(TEXT("ncrypt.dll"));
- if (ncrypt_lib == NULL) {
- return gnutls_assert_val(GNUTLS_E_CRYPTO_INIT_FAILED);
- }
---- gnutls/lib/system.c.old 2017-12-28 15:24:07.479820602 +0100
-+++ gnutls/lib/system.c 2017-12-28 15:25:33.587817242 +0100
-@@ -50,7 +50,7 @@
- #if defined(_WIN32) && defined(NEED_CERT_ENUM_CRLS)
- /* used in system/certs.c */
- HMODULE crypto;
-- crypto = LoadLibraryA("Crypt32.dll");
-+ crypto = LoadLibrary(TEXT("Crypt32.dll"));
-
- if (crypto == NULL)
- return GNUTLS_E_CRYPTO_INIT_FAILED;
diff --git a/contrib/src/gnutls/gnutls-pkgconfig-static.patch b/contrib/src/gnutls/gnutls-pkgconfig-static.patch
index 0a5ecfcef0..87964b639f 100644
--- a/contrib/src/gnutls/gnutls-pkgconfig-static.patch
+++ b/contrib/src/gnutls/gnutls-pkgconfig-static.patch
@@ -5,7 +5,7 @@ diff -ru gnutls-3.5.16/lib/gnutls.pc.in gnutls-3.5.16.patched/lib/gnutls.pc.in
URL: http://www.gnutls.org/
Version: @VERSION@
Libs: -L${libdir} -lgnutls
--Libs.private: @LIBZ_PC@ @LIBINTL@ @LIBSOCKET@ @LIBNSL@ @LIBPTHREAD@ @LIB_SELECT@ @TSS_LIBS@ @GMP_LIBS@ @LIBUNISTRING@ @LIBIDN2_LIBS@
-+Libs.private: @LIBZ@ @LIBINTL@ @LIBSOCKET@ @LIBNSL@ @LIBPTHREAD@ @LIB_SELECT@ @TSS_LIBS@ @GMP_LIBS@ @LIBUNISTRING@ @LIBIDN2_LIBS@ @LIBIDN_LIBS@ @HOGWEED_LIBS@ @NETTLE_LIBS@
+-Libs.private: @LIBINTL@ @LIBSOCKET@ @LIBNSL@ @LIBPTHREAD@ @LIB_SELECT@ @TSS_LIBS@ @GMP_LIBS@ @LIBUNISTRING@ @LIBIDN2_LIBS@ @LIBATOMIC_LIBS@
++Libs.private: @LIBINTL@ @LIBSOCKET@ @LIBNSL@ @LIBPTHREAD@ @LIB_SELECT@ @TSS_LIBS@ @GMP_LIBS@ @LIBUNISTRING@ @LIBIDN2_LIBS@ @LIBATOMIC_LIBS@ @HOGWEED_LIBS@ @NETTLE_LIBS@
@GNUTLS_REQUIRES_PRIVATE@
Cflags: -I${includedir}
diff --git a/contrib/src/gnutls/gnutls-win32.patch b/contrib/src/gnutls/gnutls-win32.patch
index 7c077432e3..b823fadd22 100644
--- a/contrib/src/gnutls/gnutls-win32.patch
+++ b/contrib/src/gnutls/gnutls-win32.patch
@@ -15,7 +15,7 @@
URL: http://www.gnutls.org/
Version: @VERSION@
Libs: -L${libdir} -lgnutls
--Libs.private: @LIBZ@ @LIBINTL@ @LIBSOCKET@ @LIBNSL@ @LIBPTHREAD@ @LIB_SELECT@ @TSS_LIBS@ @GMP_LIBS@ @LIBUNISTRING@ @LIBIDN2_LIBS@ @LIBIDN_LIBS@ @HOGWEED_LIBS@ @NETTLE_LIBS@
-+Libs.private: @LIBZ@ @LIBINTL@ @LIBSOCKET@ @LIBNSL@ -lcrypt32 @LIBPTHREAD@ @LIB_SELECT@ @TSS_LIBS@ @GMP_LIBS@ @LIBUNISTRING@ @LIBIDN2_LIBS@ @LIBIDN_LIBS@ @HOGWEED_LIBS@ @NETTLE_LIBS@
+-Libs.private: @LIBINTL@ @LIBSOCKET@ @LIBNSL@ @LIBPTHREAD@ @LIB_SELECT@ @TSS_LIBS@ @GMP_LIBS@ @LIBUNISTRING@ @LIBIDN2_LIBS@ @LIBATOMIC_LIBS@ @HOGWEED_LIBS@ @NETTLE_LIBS@
++Libs.private: @LIBINTL@ @LIBSOCKET@ @LIBNSL@ -lcrypt32 @LIBPTHREAD@ @LIB_SELECT@ @TSS_LIBS@ @GMP_LIBS@ @LIBUNISTRING@ @LIBIDN2_LIBS@ @LIBATOMIC_LIBS@ @HOGWEED_LIBS@ @NETTLE_LIBS@
@GNUTLS_REQUIRES_PRIVATE@
Cflags: -I${includedir}
diff --git a/contrib/src/gnutls/gnutls-winrt.patch b/contrib/src/gnutls/gnutls-winrt.patch
deleted file mode 100644
index f3057f35ba..0000000000
--- a/contrib/src/gnutls/gnutls-winrt.patch
+++ /dev/null
@@ -1,41 +0,0 @@
---- gnutls-3.5.16/lib/system/keys-win.c 2017-12-26 16:29:00.221119300 +0100
-+++ gnutls-3.5.16/lib/system/keys-win.c.new 2017-12-26 16:33:02.501126487 +0100
-@@ -44,6 +44,18 @@
- #include <wincrypt.h>
- #include <winbase.h>
-
-+#include <winapifamily.h>
-+#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP)
-+# if defined(_WIN32_WINNT) && _WIN32_WINNT >= 0x0A00 /* Univeral Winstore */
-+# undef CertOpenSystemStore
-+HCERTSTORE CertOpenSystemStore( HCRYPTPROV_LEGACY hprov, LPCSTR szSubsystemProtocol )
-+{
-+ return CertOpenStore( CERT_STORE_PROV_SYSTEM_A, X509_ASN_ENCODING, 0,
-+ CERT_SYSTEM_STORE_CURRENT_USER, szSubsystemProtocol );
-+}
-+# endif /* _WIN32_WINNT */
-+#endif /* WINAPI_FAMILY */
-+
- #define DYN_NCRYPT
-
- #ifdef __MINGW32__
---- gnutls/lib/system/keys-win.c.old 2017-12-28 11:04:45.599954683 +0100
-+++ gnutls/lib/system/keys-win.c 2017-12-28 11:07:37.999947957 +0100
-@@ -624,6 +624,9 @@
- -*/
- int _gnutls_privkey_import_system_url(gnutls_privkey_t pkey, const char *url)
- {
-+#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP)
-+ return GNUTLS_E_UNIMPLEMENTED_FEATURE;
-+#else
- uint8_t id[MAX_WID_SIZE];
- HCERTSTORE store = NULL;
- size_t id_size;
-@@ -873,6 +876,7 @@
-
- CertCloseStore(store, 0);
- return ret;
-+#endif
- }
-
- int _gnutls_x509_crt_import_system_url(gnutls_x509_crt_t crt, const char *url)
diff --git a/contrib/src/gnutls/rules.mak b/contrib/src/gnutls/rules.mak
index e404fe13d0..cc9d06b0f2 100644
--- a/contrib/src/gnutls/rules.mak
+++ b/contrib/src/gnutls/rules.mak
@@ -1,7 +1,7 @@
# GnuTLS
-GNUTLS_VERSION := 3.5.19
-GNUTLS_URL := https://www.gnupg.org/ftp/gcrypt/gnutls/v3.5/gnutls-$(GNUTLS_VERSION).tar.xz
+GNUTLS_VERSION := 3.6.6
+GNUTLS_URL := https://www.gnupg.org/ftp/gcrypt/gnutls/v3.6/gnutls-$(GNUTLS_VERSION).tar.xz
ifdef BUILD_NETWORK
ifndef HAVE_DARWIN_OS
@@ -22,11 +22,6 @@ gnutls: gnutls-$(GNUTLS_VERSION).tar.xz .sum-gnutls
$(APPLY) $(SRC)/gnutls/gnutls-pkgconfig-static.patch
ifdef HAVE_WIN32
$(APPLY) $(SRC)/gnutls/gnutls-win32.patch
- $(APPLY) $(SRC)/gnutls/gnutls-loadlibrary.patch
-ifdef HAVE_WINSTORE
- $(APPLY) $(SRC)/gnutls/gnutls-winrt.patch
- $(APPLY) $(SRC)/gnutls/winrt-topendir.patch
-endif
endif
ifdef HAVE_ANDROID
$(APPLY) $(SRC)/gnutls/no-create-time-h.patch
@@ -35,7 +30,6 @@ ifdef HAVE_MACOSX
$(APPLY) $(SRC)/gnutls/gnutls-disable-getentropy-osx.patch
$(APPLY) $(SRC)/gnutls/gnutls-disable-connectx-macos.patch
endif
- $(APPLY) $(SRC)/gnutls/gnutls-libidn.patch
$(call pkg_static,"lib/gnutls.pc.in")
$(UPDATE_AUTOCONFIG)
$(MOVE)
@@ -87,7 +81,6 @@ ifdef HAVE_NACL
endif
.gnutls: gnutls
- $(RECONF)
cd $< && $(GNUTLS_ENV) ./configure $(GNUTLS_CONF)
cd $< && $(MAKE) -C gl install
cd $< && $(MAKE) -C lib install
diff --git a/contrib/src/gnutls/winrt-topendir.patch b/contrib/src/gnutls/winrt-topendir.patch
deleted file mode 100644
index 6051cd0f01..0000000000
--- a/contrib/src/gnutls/winrt-topendir.patch
+++ /dev/null
@@ -1,86 +0,0 @@
---- gnutls-3.5.16/lib/x509/verify-high2.c.orig 2016-12-19 15:10:59.000000000 +0100
-+++ gnutls-3.5.16/lib/x509/verify-high2.c 2017-12-26 16:39:02.565137168 +0100
-@@ -43,6 +43,9 @@
- # endif
- #endif
-
-+#include <windows.h>
-+#include <tchar.h>
-+
- /* Convenience functions for verify-high functionality
- */
-
-@@ -368,29 +371,59 @@
- return ret;
- }
-
-+static inline char *FromWide (const wchar_t *wide)
-+{
-+ size_t len = WideCharToMultiByte (CP_UTF8, 0, wide, -1, NULL, 0, NULL, NULL);
-+ if (len == 0)
-+ return NULL;
-+
-+ char *out = (char *)malloc (len);
-+
-+ if (out)
-+ WideCharToMultiByte (CP_UTF8, 0, wide, -1, out, len, NULL, NULL);
-+ return out;
-+}
-+
-+static inline wchar_t *ToWide (const char *utf8)
-+{
-+ int len = MultiByteToWideChar (CP_UTF8, 0, utf8, -1, NULL, 0);
-+ if (len == 0)
-+ return NULL;
-+
-+ wchar_t *out = (wchar_t *)malloc (len * sizeof (wchar_t));
-+
-+ if (out)
-+ MultiByteToWideChar (CP_UTF8, 0, utf8, -1, out, len);
-+ return out;
-+}
-+
- static
- int load_dir_certs(const char *dirname,
- gnutls_x509_trust_list_t list,
- unsigned int tl_flags, unsigned int tl_vflags,
- unsigned type, unsigned crl)
- {
-- DIR *dirp;
-- struct dirent *d;
-+ _TDIR *dirp;
-+ struct _tdirent *d;
- int ret;
- int r = 0;
- char path[GNUTLS_PATH_MAX];
-
-- dirp = opendir(dirname);
-+ TCHAR* dirnameW = ToWide(dirname);
-+ dirp = _topendir(dirnameW);
-+ free(dirnameW);
- if (dirp != NULL) {
- do {
-- d = readdir(dirp);
-+ d = _treaddir(dirp);
- if (d != NULL
- #ifdef _DIRENT_HAVE_D_TYPE
- && (d->d_type == DT_REG || d->d_type == DT_LNK || d->d_type == DT_UNKNOWN)
- #endif
- ) {
-+ char* d_name = FromWide(d->d_name);
- snprintf(path, sizeof(path), "%s/%s",
-- dirname, d->d_name);
-+ dirname, d_name);
-+ free(d_name);
-
- if (crl != 0) {
- ret =
-@@ -408,7 +441,7 @@
- }
- }
- while (d != NULL);
-- closedir(dirp);
-+ _tclosedir(dirp);
- }
-
- return r;
More information about the vlc-commits
mailing list