[vlc-devel] [PATCH] contrib: don't pass compiler environment variables to Meson when cross compiling
Steve Lhomme
robux4 at ycbcr.xyz
Tue Dec 17 14:46:05 CET 2019
So it doesn't try to use them with the native compiler
---
contrib/src/main.mak | 11 ++++++-----
1 file changed, 6 insertions(+), 5 deletions(-)
diff --git a/contrib/src/main.mak b/contrib/src/main.mak
index 7d701626ba4..575f8548144 100644
--- a/contrib/src/main.mak
+++ b/contrib/src/main.mak
@@ -410,17 +410,18 @@ ifeq ($(V),1)
CMAKE += -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON
endif
-MESON = meson --default-library static --prefix "$(PREFIX)" --backend ninja \
- -Dlibdir=lib
+ifdef HAVE_CROSS_COMPILE
+MESON = CFLAGS= CXXFLAGS= LDFLAGS= CPPFLAGS= meson --cross-file $(abspath crossfile.meson)
+else
+MESON = meson
+endif
+MESON += --default-library static --prefix "$(PREFIX)" --backend ninja -Dlibdir=lib
ifndef WITH_OPTIMIZATION
MESON += --buildtype debug
else
MESON += --buildtype release
endif
-ifdef HAVE_CROSS_COMPILE
-MESON += --cross-file $(abspath crossfile.meson)
-endif
ifdef GPL
REQUIRE_GPL =
--
2.17.1
More information about the vlc-devel
mailing list