[vlc-commits] contrib: gnutls: disable the dllimport forced even in static linking

Steve Lhomme git at videolan.org
Wed May 20 10:16:06 CEST 2020


vlc | branch: master | Steve Lhomme <robux4 at ycbcr.xyz> | Tue May 19 16:41:16 2020 +0200| [799db8c8f91e93afd601278f3f4e513d67e1cec6] | committer: Steve Lhomme

contrib: gnutls: disable the dllimport forced even in static linking

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

 contrib/src/gnutls/gnutls-win32.patch | 11 -----------
 contrib/src/gnutls/rules.mak          |  2 ++
 2 files changed, 2 insertions(+), 11 deletions(-)

diff --git a/contrib/src/gnutls/gnutls-win32.patch b/contrib/src/gnutls/gnutls-win32.patch
index d851d9d7fb..f1b86f9c8a 100644
--- a/contrib/src/gnutls/gnutls-win32.patch
+++ b/contrib/src/gnutls/gnutls-win32.patch
@@ -1,14 +1,3 @@
---- gnutls.old/lib/includes/gnutls/gnutls.h.in	2016-07-01 22:44:49.319398504 +0200
-+++ gnutls/lib/includes/gnutls/gnutls.h.in	2016-07-01 22:48:00.515407625 +0200
-@@ -68,7 +68,7 @@
- #define GNUTLS_CIPHER_ARCFOUR GNUTLS_CIPHER_ARCFOUR_128
- 
- #if !defined(GNUTLS_INTERNAL_BUILD) && defined(_WIN32)
--# define _SYM_EXPORT __declspec(dllimport)
-+# define _SYM_EXPORT
- #else
- # define _SYM_EXPORT
- #endif
 --- gnutls-3.5.16/lib/gnutls.pc.in.orig	2017-12-26 16:20:40.969104489 +0100
 +++ gnutls-3.5.16/lib/gnutls.pc.in	2017-12-26 16:22:53.817108430 +0100
 @@ -19,6 +19,6 @@
diff --git a/contrib/src/gnutls/rules.mak b/contrib/src/gnutls/rules.mak
index b5febd479f..d7100387d3 100644
--- a/contrib/src/gnutls/rules.mak
+++ b/contrib/src/gnutls/rules.mak
@@ -24,6 +24,8 @@ gnutls: gnutls-$(GNUTLS_VERSION).tar.xz .sum-gnutls
 	$(APPLY) $(SRC)/gnutls/gnutls-pkgconfig-static.patch
 ifdef HAVE_WIN32
 	$(APPLY) $(SRC)/gnutls/gnutls-win32.patch
+	# disable the dllimport in static linking (pkg-config --static doesn't handle Cflags.private)
+	cd $(UNPACK_DIR) && sed -i.orig -e s/"_SYM_EXPORT __declspec(dllimport)"/"_SYM_EXPORT"/g lib/includes/gnutls/gnutls.h.in
 endif
 ifdef HAVE_ANDROID
 	$(APPLY) $(SRC)/gnutls/no-create-time-h.patch



More information about the vlc-commits mailing list