summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorBruno de Oliveira Abinader <bruno@mapbox.com>2016-06-19 12:17:52 +0300
committerBruno de Oliveira Abinader <bruno@mapbox.com>2016-06-19 12:40:49 +0300
commit87a09c51eedcb106e6738e0c88ad9b5b466e5327 (patch)
tree30d3a782a672d29e4c617b58ed6595f34c8bc255 /Makefile
parente50980793a1fc56d53967050a987ab92c7dcf89d (diff)
downloadqtlocation-mapboxgl-87a09c51eedcb106e6738e0c88ad9b5b466e5327.tar.gz
[build/qt] Use platform-specific gyp flavor when cross-compiling
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile11
1 files changed, 10 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index acb33204dd..1e4ece1055 100644
--- a/Makefile
+++ b/Makefile
@@ -231,8 +231,17 @@ QT_ENV = $(shell MASON_PLATFORM_VERSION=$(BUILD_PLATFORM_VERSION) ./platform/qt/
$(QT_OUTPUT_PATH)/config.gypi: platform/qt/scripts/configure.sh $(CONFIG_DEPENDENCIES)
$(QT_ENV) ./configure $< $@ $(BUILD_PLATFORM) $(BUILD_PLATFORM_VERSION)
+GYP_FLAVOR = make
+ifneq ($(HOST_PLATFORM),$(BUILD_PLATFORM))
+ ifeq ($(BUILD_PLATFORM), linux)
+ GYP_FLAVOR = make-linux
+ else ifeq ($(BUILD_PLATFORM), macos)
+ GYP_FLAVOR = make-mac
+ endif
+endif
+
$(QT_MAKEFILE): platform/qt/platform.gyp $(QT_OUTPUT_PATH)/config.gypi $(GYP_DEPENDENCIES)
- $(QT_ENV) $(GYP) -f make -I $(QT_OUTPUT_PATH)/config.gypi \
+ $(QT_ENV) $(GYP) -f $(GYP_FLAVOR) -I $(QT_OUTPUT_PATH)/config.gypi \
--generator-output=$(QT_OUTPUT_PATH) $<
qt-lib: $(QT_MAKEFILE)