]> git.proxmox.com Git - mirror_edk2.git/blobdiff - BaseTools/get_vsvars.bat
Maintainers.txt: Remove Network maintainers for MdeModulePkg/Universal/Network
[mirror_edk2.git] / BaseTools / get_vsvars.bat
index 7649e1dccf4701e2bca23f26c4ab85bd4ffac45e..9b5e9d24fcc4020c447c116460692a329ba42ce8 100644 (file)
@@ -3,19 +3,19 @@
 @REM\r
 @REM Copyright (c) 2013-2014, ARM Limited. All rights reserved.\r
 \r
-@REM This program and the accompanying materials\r
-@REM are licensed and made available under the terms and conditions of the BSD License\r
-@REM which accompanies this distribution.  The full text of the license may be found at\r
-@REM http://opensource.org/licenses/bsd-license.php\r
-@REM\r
-@REM THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
-@REM WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+@REM SPDX-License-Identifier: BSD-2-Clause-Patent\r
 @REM\r
 \r
 \r
 @echo off\r
 goto  :main\r
 \r
+:set_vsvars\r
+for /f "usebackq tokens=1* delims=: " %%i in (`%*`) do (\r
+  if /i "%%i"=="installationPath" call "%%j\VC\Auxiliary\Build\vcvars32.bat"\r
+)\r
+goto :EOF\r
+\r
 :read_vsvars\r
 @rem Do nothing if already found, otherwise call vsvars32.bat if there\r
 if defined VCINSTALLDIR goto :EOF\r
@@ -33,6 +33,8 @@ REM       (Or invoke the relevant vsvars32 file beforehand).
 \r
 :main\r
 if defined VCINSTALLDIR goto :done\r
+  if exist "%ProgramFiles(x86)%\Microsoft Visual Studio\Installer\vswhere.exe"  call :set_vsvars "%ProgramFiles(x86)%\Microsoft Visual Studio\Installer\vswhere.exe"\r
+  if exist "%ProgramFiles%\Microsoft Visual Studio\Installer\vswhere.exe"       call :set_vsvars "%ProgramFiles%\Microsoft Visual Studio\Installer\vswhere.exe"\r
   if defined VS140COMNTOOLS  call :read_vsvars  "%VS140COMNTOOLS%"\r
   if defined VS120COMNTOOLS  call :read_vsvars  "%VS120COMNTOOLS%"\r
   if defined VS110COMNTOOLS  call :read_vsvars  "%VS110COMNTOOLS%"\r