From c4cf10dbfced463a58c613bf5fe55786558fb154 Mon Sep 17 00:00:00 2001 From: Atul Katti Date: Thu, 1 Nov 2018 11:36:12 -0700 Subject: [PATCH] Update MSBUILD locator script to allow for a VS install at a non-default location. --- Build/scripts/add_msbuild_path.cmd | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Build/scripts/add_msbuild_path.cmd b/Build/scripts/add_msbuild_path.cmd index 538aa72cb6f..9feef583ddb 100644 --- a/Build/scripts/add_msbuild_path.cmd +++ b/Build/scripts/add_msbuild_path.cmd @@ -26,6 +26,10 @@ echo Trying to locate Dev15... set MSBUILD_VERSION=15.0 set "MSBUILD_PATH=%ProgramFiles(x86)%\Microsoft Visual Studio\Preview\Enterprise\MSBuild\15.0\Bin" +if not exist "%MSBUILD_PATH%\msbuild.exe" ( + set "MSBUILD_PATH=%VSINSTALLDIR%MSBuild\%MSBUILD_VERSION%\Bin" +) + if not exist "%MSBUILD_PATH%\msbuild.exe" ( set "MSBUILD_PATH=%ProgramFiles%\Microsoft Visual Studio\2017\Enterprise\MSBuild\%MSBUILD_VERSION%\Bin\x86" )