aboutsummaryrefslogtreecommitdiffstats
path: root/core/core.mk
diff options
context:
space:
mode:
authorLoïc Hoguin <[email protected]>2015-09-14 18:13:46 +0200
committerLoïc Hoguin <[email protected]>2015-09-14 18:13:46 +0200
commit4f59af14f2977a2d925f7b0d97caf49a4d6d31de (patch)
treef433e6d706261149d71e216a52adf9a8602bff68 /core/core.mk
parent3f7627ba58e5317aaaa0cdd665d2a2117f21b2be (diff)
downloaderlang.mk-4f59af14f2977a2d925f7b0d97caf49a4d6d31de.tar.gz
erlang.mk-4f59af14f2977a2d925f7b0d97caf49a4d6d31de.tar.bz2
erlang.mk-4f59af14f2977a2d925f7b0d97caf49a4d6d31de.zip
Make relx work on Windows/MSYS2
Diffstat (limited to 'core/core.mk')
-rw-r--r--core/core.mk8
1 files changed, 7 insertions, 1 deletions
diff --git a/core/core.mk b/core/core.mk
index c2a153c..a9cb808 100644
--- a/core/core.mk
+++ b/core/core.mk
@@ -141,6 +141,12 @@ define erlang
$(ERL) $(2) -pz $(ERLANG_MK_TMP)/rebar/ebin -eval "$(subst $(newline),,$(subst ",\",$(1)))" -- erlang.mk
endef
+ifeq ($(PLATFORM),msys2)
+core_native_path = $(subst \,\\\\,$(shell cygpath -w $1))
+else
+core_native_path = $1
+endif
+
ifeq ($(shell which wget 2>/dev/null | wc -l), 1)
define core_http_get
wget --no-check-certificate -O $(1) $(2)|| rm $(1)
@@ -162,7 +168,7 @@ define core_http_get.erl
endef
define core_http_get
- $(call erlang,$(call core_http_get.erl,$(1),$(2)))
+ $(call erlang,$(call core_http_get.erl,$(call core_native_path,$1),$2))
endef
endif