From 7369dd2631b857514a181dc0c3f005e57790c760 Mon Sep 17 00:00:00 2001 From: Steven Watanabe Date: Thu, 14 Dec 2017 12:26:24 -0700 Subject: [PATCH] Use the right setup scripts for several tools. Previously, the first setup script processed would be applied unconditionally, because api was not defined which leaves the condition blank, and later setup scripts would be applied to winapi=phone, because api was not properly localized. --- src/tools/msvc.jam | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/src/tools/msvc.jam b/src/tools/msvc.jam index f5e56e0c4..9b76225ab 100644 --- a/src/tools/msvc.jam +++ b/src/tools/msvc.jam @@ -1189,18 +1189,19 @@ local rule configure-really ( version ? : options * ) local cpu-assembler = $(assembler) ; cpu-assembler ?= $(default-assembler-$(c)) ; - toolset.flags msvc.compile .RC $(api)/$(cpu-conditions) : $(setup-$(c))$(resource-compiler) ; - toolset.flags msvc.compile .IDL $(api)/$(cpu-conditions) : $(setup-$(c))$(idl-compiler) ; - toolset.flags msvc.compile .MC $(api)/$(cpu-conditions) : $(setup-$(c))$(mc-compiler) ; - toolset.flags msvc.link .MT $(api)/$(cpu-conditions) : $(setup-$(c))$(manifest-tool) -nologo ; - - for api in desktop store phone + for local api in desktop store phone { local setup-script = $(setup-$(c)) ; if $(api) = phone { setup-script = $(setup-phone-$(c)) ; } + + toolset.flags msvc.compile .RC $(api)/$(cpu-conditions) : $(setup-script)$(resource-compiler) ; + toolset.flags msvc.compile .IDL $(api)/$(cpu-conditions) : $(setup-script)$(idl-compiler) ; + toolset.flags msvc.compile .MC $(api)/$(cpu-conditions) : $(setup-script)$(mc-compiler) ; + toolset.flags msvc.link .MT $(api)/$(cpu-conditions) : $(setup-script)$(manifest-tool) -nologo ; + if $(api) = desktop { toolset.flags msvc.compile .CC $(api)/$(cpu-conditions) : $(setup-script)$(compiler) /Zm800 -nologo ;