[vlc-commits] contrib: group the msys environment from the BUILD value

Steve Lhomme git at videolan.org
Fri Mar 8 16:24:38 CET 2019


vlc | branch: master | Steve Lhomme <robux4 at ycbcr.xyz> | Wed Mar  6 16:10:33 2019 +0100| [375b07b4dae7630b0180e121a6c40b60d3954339] | committer: Steve Lhomme

contrib: group the msys environment from the BUILD value

So building either in pure msys2 or msys2+mingw64 target is detected the same.

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

 contrib/src/main.mak | 11 +++++++++--
 1 file changed, 9 insertions(+), 2 deletions(-)

diff --git a/contrib/src/main.mak b/contrib/src/main.mak
index d3caf2c8dc..63ad43433b 100644
--- a/contrib/src/main.mak
+++ b/contrib/src/main.mak
@@ -54,6 +54,13 @@ else
 need_pkg = $(shell $(PKG_CONFIG) $(1) || echo 1)
 endif
 
+ifeq ($(findstring mingw32,$(BUILD)),mingw32)
+MSYS_BUILD := 1
+endif
+ifeq ($(findstring msys,$(BUILD)),msys)
+MSYS_BUILD := 1
+endif
+
 #
 # Default values for tools
 #
@@ -365,7 +372,7 @@ RECONF = mkdir -p -- $(PREFIX)/share/aclocal && \
 	cd $< && $(AUTORECONF) -fiv $(ACLOCAL_AMFLAGS)
 CMAKE = cmake . -DCMAKE_TOOLCHAIN_FILE=$(abspath toolchain.cmake) \
 		-DCMAKE_INSTALL_PREFIX=$(PREFIX) $(CMAKE_GENERATOR) -DCMAKE_DEBUG_POSTFIX:STRING=
-ifeq ($(findstring mingw32,$(BUILD)),mingw32)
+ifdef MSYS_BUILD
 CMAKE += -DCMAKE_LINK_LIBRARY_SUFFIX:STRING=.a
 endif
 
@@ -545,7 +552,7 @@ endif
 endif
 	echo "set(CMAKE_C_COMPILER $(CC))" >> $@
 	echo "set(CMAKE_CXX_COMPILER $(CXX))" >> $@
-ifeq ($(findstring msys,$(BUILD)),msys)
+ifdef MSYS_BUILD
 	echo "set(CMAKE_FIND_ROOT_PATH `cygpath -m $(PREFIX)`)" >> $@
 else
 	echo "set(CMAKE_FIND_ROOT_PATH $(PREFIX))" >> $@



More information about the vlc-commits mailing list