WIN_PS_TOOLS := defined
endif
endif
+slash_path = $(subst $(backslash),$(slash),$(1))
ifdef WIN_PS_TOOLS
psep := $(backslash)
- slash_path = $(subst $(backslash),$(slash),$(1))
sys_path = $(subst $(backslash)$(backslash),$(slash),$(subst $(slash),$(backslash),$(1)))
quote_path = "$(call sys_path,$(call unescp_all,$(1)))"
each_path_quote = $(if $(findstring $(esc),$(path)),"$(call unescp_all,$(call shwspace,$(path)))",$(call unescp_all,$(path)))
sys_path_list = $(foreach path,$(1),$(each_path_quote))
else
psep := $(slash)
- slash_path = $(1)
sys_path = $(1)
quote_path = $(1)
endif
echo = $(if $(1),echo $(1))
touch = $(if $(1),@cmd /c "for %%I in ($(call sys_path,$(1))) do @(cd %%~pI && type nul >> %%~nxI && copy /by %%~nxI+,, > nul 2>&1 && cd %%cd%%)")
cp = $(if $(1),@cmd /c "for %%I in ($(call sys_path,$(1))) do copy /by %%I $(call sys_path,$(2))"$(if $(SILENT_IS_ON), > nul,))
- cpr = $(if $(1),xcopy /y /s$(if $(SILENT_IS_ON), /q,) $(call sys_path,$(call sys_path_list,$(1))) $(call sys_path,$(2))$(if $(SILENT_IS_ON), > nul,))
+ cpr = $(if $(1),xcopy /y /i /e$(if $(SILENT_IS_ON), /q,) $(call sys_path,$(call sys_path_list,$(1))) $(call sys_path,$(2))$(if $(SILENT_IS_ON), > nul,))
rm = $(if $(1),-del /f$(if $(SILENT_IS_ON), /q,) $(call sys_path,$(call sys_path_list,$(1)))$(if $(SILENT_IS_ON), > nul,)$(if $(DEBUG_IS_ON),, 2>&1))
rmr = $(if $(1),-rmdir /s$(if $(SILENT_IS_ON), /q,) $(call sys_path,$(1))$(if $(SILENT_IS_ON), > nul,))
mkdir = $(if $(1),-mkdir $(call sys_path,$(1))$(if $(SILENT_IS_ON), > nul,)$(if $(DEBUG_IS_ON),, 2>&1))
echo = $(if $(1),echo "$(1)")
touch = $(if $(1),touch $(1))
cp = $(if $(1),cp$(if $(SILENT_IS_ON),, -v) $(1) $(2))
- cpr = $(if $(1),cp -r$(if $(SILENT_IS_ON),,v) $(1) $(2))
+ cpr = $(if $(1),cp -prf$(if $(SILENT_IS_ON),,v) $(1) $(2))
rm = $(if $(1),-rm -f$(if $(SILENT_IS_ON),,v) $(1))
rmr = $(if $(1),-rm -fr$(if $(SILENT_IS_ON),,v) $(1))
mkdir = $(if $(1),-mkdir -p$(if $(SILENT_IS_ON),,v) $(1))