[vlc-commits] contrib: fix building zlib under mingw
Steve Lhomme
git at videolan.org
Fri Feb 26 18:34:51 CET 2016
vlc | branch: master | Steve Lhomme <robUx4 at videolabs.io> | Fri Feb 26 09:29:30 2016 +0100| [dd5040ae894109fb2d932c27c6b9512de0f5390c] | committer: Jean-Baptiste Kempf
contrib: fix building zlib under mingw
Otherwise we just get the error message "Please use win32/Makefile.gcc instead."
And win32/Makefile.gcc is not usable with our CFLAGS
Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=dd5040ae894109fb2d932c27c6b9512de0f5390c
---
contrib/src/zlib/mingw.patch | 11 +++++++++++
contrib/src/zlib/rules.mak | 3 +++
2 files changed, 14 insertions(+)
diff --git a/contrib/src/zlib/mingw.patch b/contrib/src/zlib/mingw.patch
new file mode 100644
index 0000000..3439d99
--- /dev/null
+++ b/contrib/src/zlib/mingw.patch
@@ -0,0 +1,11 @@
+--- zlib/configure 2016-02-25 16:35:50.228444200 +0100
++++ zlib/configure.mingw 2016-02-25 16:34:19.725510100 +0100
+@@ -194,7 +194,7 @@ if test "$gcc" -eq 1 && ($cc -c $test.c)
+ # temporary bypass
+ rm -f $test.[co] $test $test$shared_ext
+ echo "Please use win32/Makefile.gcc instead." | tee -a configure.log
+- leave 1
++# leave 1
+ LDSHARED=${LDSHARED-"$cc -shared"}
+ LDSHAREDLIBC=""
+ EXE='.exe' ;;
diff --git a/contrib/src/zlib/rules.mak b/contrib/src/zlib/rules.mak
index d5f1e9e..5728d58 100644
--- a/contrib/src/zlib/rules.mak
+++ b/contrib/src/zlib/rules.mak
@@ -24,6 +24,9 @@ $(TARBALLS)/zlib-$(ZLIB_VERSION).tar.gz:
zlib: zlib-$(ZLIB_VERSION).tar.gz .sum-zlib
$(UNPACK)
+ifdef HAVE_WIN32
+ $(APPLY) $(SRC)/zlib/mingw.patch
+endif
$(MOVE)
.zlib: zlib
More information about the vlc-commits
mailing list