[vlc-commits] contrib: gnutls: Drop mac keychain lookup patch

David Fuhrmann git at videolan.org
Thu Dec 28 00:12:54 CET 2017


vlc/vlc-3.0 | branch: master | David Fuhrmann <dfuhrmann at videolan.org> | Wed Dec 27 18:27:12 2017 +0100| [adaab724928913aef3784c982b8f550ac9d04f2d] | committer: Jean-Baptiste Kempf

contrib: gnutls: Drop mac keychain lookup patch

Similar code is now part of the release itself, therefore this
patch is not needed anymore.

(cherry picked from commit 1a0717116afa72a2c1dae47e31c56c2926b584d6)
Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>

> http://git.videolan.org/gitweb.cgi/vlc/vlc-3.0.git/?a=commit;h=adaab724928913aef3784c982b8f550ac9d04f2d
---

 contrib/src/gnutls/mac-keychain-lookup.patch | 59 ----------------------------
 contrib/src/gnutls/rules.mak                 |  1 -
 2 files changed, 60 deletions(-)

diff --git a/contrib/src/gnutls/mac-keychain-lookup.patch b/contrib/src/gnutls/mac-keychain-lookup.patch
deleted file mode 100644
index 2c18260754..0000000000
--- a/contrib/src/gnutls/mac-keychain-lookup.patch
+++ /dev/null
@@ -1,59 +0,0 @@
---- gnutls-old/lib/Makefile.am
-+++ gnutls/lib/Makefile.am
-@@ -206,6 +206,10 @@
- thirdparty_libadd += -lcrypt32
- endif
- 
-+if MACOSX
-+libgnutls_la_LDFLAGS +=  -Wl,-framework,Security,-framework,CoreFoundation
-+endif
-+
- libgnutls_la_LIBADD += $(thirdparty_libadd)
- 
- # C++ library
---- gnutls-old/lib/system/certs.c
-+++ gnutls/lib/system/certs.c
-@@ -270,6 +270,43 @@
- 
- 	return r;
- }
-+
-+#elif defined(__APPLE__) && TARGET_OS_MAC
-+
-+#include "TargetConditionals.h"
-+#define _UINT64
-+#include <Security/Security.h>
-+#include <Security/SecCertificate.h>
-+
-+static
-+int add_system_trust(gnutls_x509_trust_list_t list, unsigned int tl_flags, unsigned int tl_vflags)
-+{
-+    CFArrayRef anchors;
-+    int ret = 0;
-+    if (SecTrustCopyAnchorCertificates(&anchors) != 0)
-+        return -1;
-+
-+    CFIndex count = CFArrayGetCount(anchors);
-+    for (int i = 0; i < count; i++) {
-+        SecCertificateRef certref = (SecCertificateRef)CFArrayGetValueAtIndex(anchors, i);
-+
-+        CSSM_DATA certData;
-+        SecCertificateGetData(certref, &certData);
-+        gnutls_datum data = {
-+            .data = certData.Data,
-+            .size = certData.Length,
-+        };
-+
-+        if (!gnutls_x509_trust_list_add_trust_mem(list, &data, NULL, GNUTLS_X509_FMT_DER, tl_flags, tl_vflags))
-+            printf("cannot add x509 credentials\n");
-+        else
-+            ret++;
-+    }
-+    CFRelease(anchors);
-+
-+    return ret;
-+}
-+
- #else
- 
- #define add_system_trust(x,y,z) GNUTLS_E_UNIMPLEMENTED_FEATURE
diff --git a/contrib/src/gnutls/rules.mak b/contrib/src/gnutls/rules.mak
index e537d9d2f2..2ebe6b8eb5 100644
--- a/contrib/src/gnutls/rules.mak
+++ b/contrib/src/gnutls/rules.mak
@@ -33,7 +33,6 @@ ifdef HAVE_ANDROID
 endif
 	$(APPLY) $(SRC)/gnutls/read-file-limits.h.patch
 ifdef HAVE_MACOSX
-	$(APPLY) $(SRC)/gnutls/mac-keychain-lookup.patch
 	$(APPLY) $(SRC)/gnutls/gnutls-pkgconfig-osx.patch
 	$(APPLY) $(SRC)/gnutls/gnutls-disable-getentropy-osx.patch
 	$(APPLY) $(SRC)/gnutls/gnutls-disable-connectx-macos.patch



More information about the vlc-commits mailing list