From 8206a01c99ed929327365a16915233a867c54aed Mon Sep 17 00:00:00 2001 From: Refael Ackermann Date: Mon, 19 Jun 2017 20:11:22 -0400 Subject: [PATCH] build,win: skip `vcvarsall.bat` if env is set MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit PR-URL: https://github.com/nodejs/node/pull/13806 Fixes: https://github.com/nodejs/node/issues/13765 Reviewed-By: Richard Lau Reviewed-By: Kunal Pathak Reviewed-By: Tobias Nießen Reviewed-By: James M Snell --- vcbuild.bat | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vcbuild.bat b/vcbuild.bat index a1c011780cbef6..0af8047e4a0e96 100644 --- a/vcbuild.bat +++ b/vcbuild.bat @@ -200,9 +200,12 @@ if defined msi ( goto wix-not-found ) ) -@rem VS2015 vsvarsall is quick, so run anyway + +@rem check if VS2015 is already setup +if "_%VisualStudioVersion%_" == "_14.0_" if "_%VCVARS_VER%_" == "_140_" goto found_vs2015 call "%VS140COMNTOOLS%\..\..\vc\vcvarsall.bat" SET VCVARS_VER=140 +:found_vs2015 if not defined VCINSTALLDIR goto msbuild-not-found @rem Visual C++ Build Tools 2015 does not define VisualStudioVersion echo Found MSVS version 14.0