diff options
author | Jose Perez Rodriguez <joperezr@microsoft.com> | 2017-10-03 15:21:52 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-10-03 15:21:52 -0700 |
commit | aae414026671e3dc1ccf0f308d351ac04cc746a4 (patch) | |
tree | 7854947379c68e2b03c476f3744db1a699cf1b6a /run.cmd | |
parent | 3716918ee67ea2e8d8271c9a214159e56687f043 (diff) | |
download | coreclr-aae414026671e3dc1ccf0f308d351ac04cc746a4.tar.gz coreclr-aae414026671e3dc1ccf0f308d351ac04cc746a4.tar.bz2 coreclr-aae414026671e3dc1ccf0f308d351ac04cc746a4.zip |
Update Buildtools and Roslyn (#14228)
* Update Buildtools and Roslyn
* Fixing importing of the roslyn files on msbuild 14.0
* Correctly looking for the latest VS Installation
Diffstat (limited to 'run.cmd')
-rw-r--r-- | run.cmd | 26 |
1 files changed, 10 insertions, 16 deletions
@@ -16,27 +16,21 @@ setlocal :: is already configured to use that toolset. Otherwise, we will fallback to using the VS2015 :: toolset if it is installed. Finally, we will fail the script if no supported VS instance :: can be found. -if not defined VisualStudioVersion ( - if defined VS150COMNTOOLS ( - if not exist "%VS150COMNTOOLS%\..\IDE\devenv.exe" goto NoVS - if not exist "%VS150COMNTOOLS%\..\..\VC\Auxiliary\Build\vcvarsall.bat" goto NoVS - if not exist "%VS150COMNTOOLS%\VsDevCmd.bat" goto NoVS - call "%VS150COMNTOOLS%\VsDevCmd.bat" - goto :Run - ) else if defined VS140COMNTOOLS ( - if not exist "%VS140COMNTOOLS%\..\IDE\devenv.exe" goto NoVS - if not exist "%VS140COMNTOOLS%\..\..\VC\vcvarsall.bat" goto NoVS - if not exist "%VS140COMNTOOLS%\VsDevCmd.bat" goto NoVS - call "%VS140COMNTOOLS%\VsDevCmd.bat" - goto :Run - ) +if defined VisualStudioVersion goto :Run - :NoVS +set _VSWHERE="%ProgramFiles(x86)%\Microsoft Visual Studio\Installer\vswhere.exe" +if exist %_VSWHERE% ( + for /f "usebackq tokens=*" %%i in (`%_VSWHERE% -latest -property installationPath`) do set _VSCOMNTOOLS=%%i\Common7\Tools +) +if not exist "%_VSCOMNTOOLS%" set _VSCOMNTOOLS=%VS140COMNTOOLS% +if not exist "%_VSCOMNTOOLS%" ( echo Error: Visual Studio 2015 or 2017 required. - echo https://github.com/dotnet/coreclr/blob/master/Documentation/building/windows-instructions.md for build instructions. + echo Please see https://github.com/dotnet/corefx/blob/master/Documentation/project-docs/developer-guide.md for build instructions. exit /b 1 ) +call "%_VSCOMNTOOLS%\VsDevCmd.bat" + :Run :: Clear the 'Platform' env variable for this session, as it's a per-project setting within the build, and :: misleading value (such as 'MCD' in HP PCs) may lead to build breakage (issue: #69). |