From 83fbbe896411ff0f12c7e12d7816f4e19eecf984 Mon Sep 17 00:00:00 2001 From: Jimmy Brisson Date: Thu, 3 Nov 2016 15:38:55 -0500 Subject: [PATCH 1/2] Quote the shell call in mkdir and rmdir Allows the use of bash in windows --- tools/export/makefile/Makefile.tmpl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/export/makefile/Makefile.tmpl b/tools/export/makefile/Makefile.tmpl index a22cb9c23fd..98bcd26f35b 100644 --- a/tools/export/makefile/Makefile.tmpl +++ b/tools/export/makefile/Makefile.tmpl @@ -9,8 +9,8 @@ ifeq ($(shell echo $$OS),$$OS) MAKEDIR = if not exist "$(1)" mkdir "$(1)" RM = rmdir /S /Q "$(1)" else - MAKEDIR = $(SHELL) -c "mkdir -p \"$(1)\"" - RM = $(SHELL) -c "rm -rf \"$(1)\"" + MAKEDIR = '$(SHELL)' -c "mkdir -p \"$(1)\"" + RM = '$(SHELL)' -c "rm -rf \"$(1)\"" endif # Move to the build directory From 688d55bd93e353238f091fc925c847f126789daf Mon Sep 17 00:00:00 2001 From: Jimmy Brisson Date: Fri, 4 Nov 2016 10:08:24 -0500 Subject: [PATCH 2/2] Quote make invocation too --- tools/export/makefile/Makefile.tmpl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/export/makefile/Makefile.tmpl b/tools/export/makefile/Makefile.tmpl index 98bcd26f35b..b93950099d1 100644 --- a/tools/export/makefile/Makefile.tmpl +++ b/tools/export/makefile/Makefile.tmpl @@ -18,8 +18,8 @@ ifeq (,$(filter .build,$(notdir $(CURDIR)))) .SUFFIXES: OBJDIR := .build mkfile_path := $(abspath $(lastword $(MAKEFILE_LIST))) -MAKETARGET = $(MAKE) --no-print-directory -C $(OBJDIR) -f $(mkfile_path) \ - SRCDIR=$(CURDIR) $(MAKECMDGOALS) +MAKETARGET = '$(MAKE)' --no-print-directory -C $(OBJDIR) -f '$(mkfile_path)' \ + 'SRCDIR=$(CURDIR)' $(MAKECMDGOALS) .PHONY: $(OBJDIR) clean all: +@$(call MAKEDIR,$(OBJDIR))