]> git.proxmox.com Git - ceph.git/blobdiff - ceph/src/boost/tools/build/src/engine/guess_toolset.bat
import quincy beta 17.1.0
[ceph.git] / ceph / src / boost / tools / build / src / engine / guess_toolset.bat
index 51d2d26c10e57c57b61ad2acf6387f1f0ade346e..3565ac91722d0ad79a4cdad34c98dd7d20742850 100644 (file)
-@ECHO OFF
-
-REM ~ Copyright 2002-2018 Rene Rivera.
-REM ~ Distributed under the Boost Software License, Version 1.0.
-REM ~ (See accompanying file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt)
-
-if "_%1_" == "_yacc_" goto Guess_Yacc
-if "_%1_" == "_test_path_" (
-    shift
-    goto Test_Path)
-goto Guess
-
-
-:Clear_Error
-ver >nul
-goto :eof
-
-
-:Test_Path
-REM Tests for the given executable file presence in the directories in the PATH
-REM environment variable. Additionally sets FOUND_PATH to the path of the
-REM found file.
-call :Clear_Error
-setlocal
-set test=%~$PATH:1
-endlocal
-if not errorlevel 1 set FOUND_PATH=%~dp$PATH:1
-goto :eof
-
-
-:Guess
-REM Let vswhere tell us where msvc is at, if available.
-call :Clear_Error
-call vswhere_usability_wrapper.cmd
-call :Clear_Error
-REM VSUNKCOMNTOOLS represents unknown but detected version from vswhere
-if NOT "_%VSUNKCOMNTOOLS%_" == "__" (
-    set "B2_TOOLSET=vcunk"
-    set "B2_TOOLSET_ROOT=%VSUNKCOMNTOOLS%..\..\VC\"
-    goto :eof)
-if NOT "_%VS160COMNTOOLS%_" == "__" (
-    set "B2_TOOLSET=vc142"
-    set "B2_TOOLSET_ROOT=%VS160COMNTOOLS%..\..\VC\"
-    goto :eof)
-if NOT "_%VS150COMNTOOLS%_" == "__" (
-    set "B2_TOOLSET=vc141"
-    set "B2_TOOLSET_ROOT=%VS150COMNTOOLS%..\..\VC\"
-    goto :eof)
-if EXIST "%VS_ProgramFiles%\Microsoft Visual Studio\2017\Enterprise\VC\Auxiliary\Build\vcvarsall.bat"  (
-    set "B2_TOOLSET=vc141"
-    set "B2_TOOLSET_ROOT=%VS_ProgramFiles%\Microsoft Visual Studio\2017\Enterprise\VC\"
-    exit /b 0)
-if EXIST "%VS_ProgramFiles%\Microsoft Visual Studio\2017\Professional\VC\Auxiliary\Build\vcvarsall.bat"  (
-    set "B2_TOOLSET=vc141"
-    set "B2_TOOLSET_ROOT=%VS_ProgramFiles%\Microsoft Visual Studio\2017\Professional\VC\"
-    exit /b 0)
-if EXIST "%VS_ProgramFiles%\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build\vcvarsall.bat"  (
-    set "B2_TOOLSET=vc141"
-    set "B2_TOOLSET_ROOT=%VS_ProgramFiles%\Microsoft Visual Studio\2017\Community\VC\"
-    exit /b 0)
-if NOT "_%VS140COMNTOOLS%_" == "__" (
-    set "B2_TOOLSET=vc14"
-    set "B2_TOOLSET_ROOT=%VS140COMNTOOLS%..\..\VC\"
-    exit /b 0)
-if EXIST "%VS_ProgramFiles%\Microsoft Visual Studio 14.0\VC\VCVARSALL.BAT" (
-    set "B2_TOOLSET=vc14"
-    set "B2_TOOLSET_ROOT=%VS_ProgramFiles%\Microsoft Visual Studio 14.0\VC\"
-    exit /b 0)
-if NOT "_%VS120COMNTOOLS%_" == "__" (
-    set "B2_TOOLSET=vc12"
-    set "B2_TOOLSET_ROOT=%VS120COMNTOOLS%..\..\VC\"
-    exit /b 0)
-if EXIST "%VS_ProgramFiles%\Microsoft Visual Studio 12.0\VC\VCVARSALL.BAT" (
-    set "B2_TOOLSET=vc12"
-    set "B2_TOOLSET_ROOT=%VS_ProgramFiles%\Microsoft Visual Studio 12.0\VC\"
-    exit /b 0)
-if NOT "_%VS110COMNTOOLS%_" == "__" (
-    set "B2_TOOLSET=vc11"
-    set "B2_TOOLSET_ROOT=%VS110COMNTOOLS%..\..\VC\"
-    exit /b 0)
-if EXIST "%VS_ProgramFiles%\Microsoft Visual Studio 11.0\VC\VCVARSALL.BAT" (
-    set "B2_TOOLSET=vc11"
-    set "B2_TOOLSET_ROOT=%VS_ProgramFiles%\Microsoft Visual Studio 11.0\VC\"
-    exit /b 0)
-call :Test_Path cl.exe
-if not errorlevel 1 (
-    set "B2_TOOLSET=msvc"
-    set "B2_TOOLSET_ROOT=%FOUND_PATH%..\"
-    exit /b 0)
-call :Test_Path vcvars32.bat
-if not errorlevel 1 (
-    set "B2_TOOLSET=msvc"
-    call "%FOUND_PATH%VCVARS32.BAT"
-    set "B2_TOOLSET_ROOT=%MSVCDir%\"
-    exit /b 0)
-if EXIST "C:\Borland\BCC55\Bin\bcc32.exe" (
-    set "B2_TOOLSET=borland"
-    set "B2_TOOLSET_ROOT=C:\Borland\BCC55\"
-    exit /b 0)
-call :Test_Path bcc32.exe
-if not errorlevel 1 (
-    set "B2_TOOLSET=borland"
-    set "B2_TOOLSET_ROOT=%FOUND_PATH%..\"
-    exit /b 0)
-call :Test_Path icl.exe
-if not errorlevel 1 (
-    set "B2_TOOLSET=intel-win32"
-    set "B2_TOOLSET_ROOT=%FOUND_PATH%..\"
-    exit /b 0)
-if EXIST "C:\MinGW\bin\gcc.exe" (
-    set "B2_TOOLSET=mingw"
-    set "B2_TOOLSET_ROOT=C:\MinGW\"
-    exit /b 0)
-REM Could not find a suitable toolset
-exit /b 1
+@ECHO OFF\r
+\r
+REM ~ Copyright 2002-2018 Rene Rivera.\r
+REM ~ Distributed under the Boost Software License, Version 1.0.\r
+REM ~ (See accompanying file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt)\r
+\r
+if "_%1_" == "_yacc_" goto Guess_Yacc\r
+if "_%1_" == "_test_path_" (\r
+    shift\r
+    goto Test_Path)\r
+goto Guess\r
+\r
+\r
+:Clear_Error\r
+ver >nul\r
+goto :eof\r
+\r
+\r
+:Test_Path\r
+REM Tests for the given executable file presence in the directories in the PATH\r
+REM environment variable. Additionally sets FOUND_PATH to the path of the\r
+REM found file.\r
+call :Clear_Error\r
+setlocal\r
+set test=%~$PATH:1\r
+endlocal\r
+if not errorlevel 1 set FOUND_PATH=%~dp$PATH:1\r
+goto :eof\r
+\r
+\r
+:Guess\r
+REM Let vswhere tell us where msvc is at, if available.\r
+call :Clear_Error\r
+call vswhere_usability_wrapper.cmd\r
+call :Clear_Error\r
+if NOT "_%VS160COMNTOOLS%_" == "__" (\r
+    set "B2_TOOLSET=vc142"\r
+    set "B2_TOOLSET_ROOT=%VS160COMNTOOLS%..\..\VC\"\r
+    goto :eof)\r
+if NOT "_%VS150COMNTOOLS%_" == "__" (\r
+    set "B2_TOOLSET=vc141"\r
+    set "B2_TOOLSET_ROOT=%VS150COMNTOOLS%..\..\VC\"\r
+    goto :eof)\r
+REM VSUNKCOMNTOOLS represents unknown but detected version from vswhere\r
+if NOT "_%VSUNKCOMNTOOLS%_" == "__" (\r
+    set "B2_TOOLSET=vcunk"\r
+    set "B2_TOOLSET_ROOT=%VSUNKCOMNTOOLS%..\..\VC\"\r
+    goto :eof)\r
+if EXIST "%VS_ProgramFiles%\Microsoft Visual Studio\2017\Enterprise\VC\Auxiliary\Build\vcvarsall.bat"  (\r
+    set "B2_TOOLSET=vc141"\r
+    set "B2_TOOLSET_ROOT=%VS_ProgramFiles%\Microsoft Visual Studio\2017\Enterprise\VC\"\r
+    exit /b 0)\r
+if EXIST "%VS_ProgramFiles%\Microsoft Visual Studio\2017\Professional\VC\Auxiliary\Build\vcvarsall.bat"  (\r
+    set "B2_TOOLSET=vc141"\r
+    set "B2_TOOLSET_ROOT=%VS_ProgramFiles%\Microsoft Visual Studio\2017\Professional\VC\"\r
+    exit /b 0)\r
+if EXIST "%VS_ProgramFiles%\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build\vcvarsall.bat"  (\r
+    set "B2_TOOLSET=vc141"\r
+    set "B2_TOOLSET_ROOT=%VS_ProgramFiles%\Microsoft Visual Studio\2017\Community\VC\"\r
+    exit /b 0)\r
+if NOT "_%VS140COMNTOOLS%_" == "__" (\r
+    set "B2_TOOLSET=vc14"\r
+    set "B2_TOOLSET_ROOT=%VS140COMNTOOLS%..\..\VC\"\r
+    exit /b 0)\r
+if EXIST "%VS_ProgramFiles%\Microsoft Visual Studio 14.0\VC\VCVARSALL.BAT" (\r
+    set "B2_TOOLSET=vc14"\r
+    set "B2_TOOLSET_ROOT=%VS_ProgramFiles%\Microsoft Visual Studio 14.0\VC\"\r
+    exit /b 0)\r
+if NOT "_%VS120COMNTOOLS%_" == "__" (\r
+    set "B2_TOOLSET=vc12"\r
+    set "B2_TOOLSET_ROOT=%VS120COMNTOOLS%..\..\VC\"\r
+    exit /b 0)\r
+if EXIST "%VS_ProgramFiles%\Microsoft Visual Studio 12.0\VC\VCVARSALL.BAT" (\r
+    set "B2_TOOLSET=vc12"\r
+    set "B2_TOOLSET_ROOT=%VS_ProgramFiles%\Microsoft Visual Studio 12.0\VC\"\r
+    exit /b 0)\r
+call :Test_Path cl.exe\r
+if not errorlevel 1 (\r
+    set "B2_TOOLSET=msvc"\r
+    set "B2_TOOLSET_ROOT=%FOUND_PATH%..\"\r
+    exit /b 0)\r
+call :Test_Path vcvars32.bat\r
+if not errorlevel 1 (\r
+    set "B2_TOOLSET=msvc"\r
+    call "%FOUND_PATH%VCVARS32.BAT"\r
+    set "B2_TOOLSET_ROOT=%MSVCDir%\"\r
+    exit /b 0)\r
+if EXIST "C:\Borland\BCC55\Bin\bcc32.exe" (\r
+    set "B2_TOOLSET=borland"\r
+    set "B2_TOOLSET_ROOT=C:\Borland\BCC55\"\r
+    exit /b 0)\r
+call :Test_Path bcc32.exe\r
+if not errorlevel 1 (\r
+    set "B2_TOOLSET=borland"\r
+    set "B2_TOOLSET_ROOT=%FOUND_PATH%..\"\r
+    exit /b 0)\r
+call :Test_Path icl.exe\r
+if not errorlevel 1 (\r
+    set "B2_TOOLSET=intel-win32"\r
+    set "B2_TOOLSET_ROOT=%FOUND_PATH%..\"\r
+    exit /b 0)\r
+if EXIST "C:\MinGW\bin\gcc.exe" (\r
+    set "B2_TOOLSET=mingw"\r
+    set "B2_TOOLSET_ROOT=C:\MinGW\"\r
+    exit /b 0)\r
+REM Could not find a suitable toolset\r
+exit /b 1\r