From 81cbff29d578fd007d010d7f08dbc136fdbab8d7 Mon Sep 17 00:00:00 2001 From: Sebastian Weber Date: Tue, 8 Oct 2019 14:19:17 +0200 Subject: [PATCH] allow spaces in path leading to stan-directory in makefiles --- make/compiler_flags | 7 ++++--- make/libraries | 4 ++-- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/make/compiler_flags b/make/compiler_flags index cb28b780fa0..e745e019775 100644 --- a/make/compiler_flags +++ b/make/compiler_flags @@ -189,6 +189,7 @@ endif # TBB_LIBRARIES variable overrides the default. TBB_BIN ?= $(MATH)lib/tbb +TBB_RELATIVE_PATH ?= ../$(notdir $(TBB)) TBB_BIN_ABSOLUTE_PATH = $(abspath $(TBB_BIN)) TBB_ABSOLUTE_PATH = $(abspath $(TBB)) @@ -199,13 +200,13 @@ else endif ifeq ($(OS),Windows_NT) - TBB_TARGETS ?= $(addsuffix $(LIBRARY_SUFFIX),$(addprefix $(TBB_BIN)/,$(TBB_LIBRARIES))) + TBB_TARGETS ?= $(addprefix $(TBB_BIN)/,$(addsuffix $(LIBRARY_SUFFIX),$(TBB_LIBRARIES))) endif ifeq ($(OS),Darwin) - TBB_TARGETS ?= $(addsuffix $(LIBRARY_SUFFIX),$(addprefix $(TBB_BIN)/lib,$(TBB_LIBRARIES))) + TBB_TARGETS ?= $(addprefix $(TBB_BIN)/lib,$(addsuffix $(LIBRARY_SUFFIX), $(TBB_LIBRARIES))) endif ifeq ($(OS),Linux) - TBB_TARGETS ?= $(addsuffix $(LIBRARY_SUFFIX).2,$(addprefix $(TBB_BIN)/lib,$(TBB_LIBRARIES))) + TBB_TARGETS ?= $(addprefix $(TBB_BIN)/lib,$(addsuffix $(LIBRARY_SUFFIX).2,$(TBB_LIBRARIES))) endif diff --git a/make/libraries b/make/libraries index 7a3089be627..30876ea0728 100644 --- a/make/libraries +++ b/make/libraries @@ -137,11 +137,11 @@ $(TBB_BIN)/tbb-make-check: $(TBB_BIN)/tbb.def: $(TBB_BIN)/tbb-make-check $(TBB_BIN)/tbbmalloc.def @mkdir -p $(TBB_BIN) touch $(TBB_BIN)/version_$(notdir $(TBB)) - tbb_root="$(TBB_ABSOLUTE_PATH)" CXX="$(CXX)" CC="$(TBB_CC)" LDFLAGS="$(LDFLAGS_TBB)" $(MAKE) -C $(TBB_BIN) -r -f "$(TBB_ABSOLUTE_PATH)/build/Makefile.tbb" compiler=$(TBB_CXX_TYPE) cfg=release stdver=c++1y + tbb_root="$(TBB_RELATIVE_PATH)" CXX="$(CXX)" CC="$(TBB_CC)" LDFLAGS='$(LDFLAGS_TBB)' $(MAKE) -C "$(TBB_BIN)" -r -f "$(TBB_ABSOLUTE_PATH)/build/Makefile.tbb" compiler=$(TBB_CXX_TYPE) cfg=release stdver=c++1y $(TBB_BIN)/tbbmalloc.def: $(TBB_BIN)/tbb-make-check @mkdir -p $(TBB_BIN) - tbb_root="$(TBB_ABSOLUTE_PATH)" CXX="$(CXX)" CC="$(TBB_CC)" LDFLAGS="$(LDFLAGS_TBB)" $(MAKE) -C $(TBB_BIN) -r -f "$(TBB_ABSOLUTE_PATH)/build/Makefile.tbbmalloc" compiler=$(TBB_CXX_TYPE) cfg=release stdver=c++1y malloc + tbb_root="$(TBB_RELATIVE_PATH)" CXX="$(CXX)" CC="$(TBB_CC)" LDFLAGS='$(LDFLAGS_TBB)' $(MAKE) -C "$(TBB_BIN)" -r -f "$(TBB_ABSOLUTE_PATH)/build/Makefile.tbbmalloc" compiler=$(TBB_CXX_TYPE) cfg=release stdver=c++1y malloc $(TBB_BIN)/libtbb.dylib: $(TBB_BIN)/tbb.def $(TBB_BIN)/libtbbmalloc.dylib: $(TBB_BIN)/tbbmalloc.def