Skip to content

Commit

Permalink
Release v18.12.
Browse files Browse the repository at this point in the history
  • Loading branch information
zufuliu committed Dec 30, 2018
1 parent ca7b93b commit 063afe8
Show file tree
Hide file tree
Showing 10 changed files with 338 additions and 13 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
dist/LLVM*/
*.pyc
*.pyo
*.plist
*.orig
*.zip
1 change: 1 addition & 0 deletions VS2015/install.bat
Original file line number Diff line number Diff line change
Expand Up @@ -83,3 +83,4 @@ IF %SUCCESS% == 0 (

POPD
ENDLOCAL
EXIST /B
1 change: 1 addition & 0 deletions VS2017/install.bat
Original file line number Diff line number Diff line change
Expand Up @@ -37,3 +37,4 @@ XCOPY /Q /Y "LLVM_v141" "%VCT_PATH%\ARM64\PlatformToolsets\LLVM_v141\"
IF "%EXIST_ON_ERROR%" == "" PAUSE
POPD
ENDLOCAL
EXIST /B
35 changes: 35 additions & 0 deletions dist/install_VS2010.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
@ECHO OFF
SETLOCAL ENABLEEXTENSIONS

SET "EXIST_ON_ERROR=%~1"
SET SUCCESS=0

PUSHD %~dp0

@rem Visual Studio 2010
:TRY_2010
SET VCT_PATH=%ProgramFiles(x86)%\MSBuild\Microsoft.Cpp\v4.0\Platforms
IF EXIST "%VCT_PATH%" GOTO FIND_2010
SET VCT_PATH=%ProgramFiles%\MSBuild\Microsoft.Cpp\v4.0\Platforms
IF EXIST "%VCT_PATH%" GOTO FIND_2010
GOTO VC_NOT_FOUND

:FIND_2010
ECHO VCTargetsPath for Visual Studio 2010: %VCT_PATH%
XCOPY /Q /Y "LLVM" "%VCT_PATH%\..\LLVM\"
XCOPY /Q /Y "x64\LLVM_v100" "%VCT_PATH%\x64\PlatformToolsets\LLVM_v100\"
XCOPY /Q /Y "Win32\LLVM_v100" "%VCT_PATH%\Win32\PlatformToolsets\LLVM_v100\"
XCOPY /Q /Y "x64\LLVM_v90" "%VCT_PATH%\x64\PlatformToolsets\LLVM_v90\"
XCOPY /Q /Y "Win32\LLVM_v90" "%VCT_PATH%\Win32\PlatformToolsets\LLVM_v90\"
SET SUCCESS=1


:VC_NOT_FOUND
IF %SUCCESS% == 0 (
ECHO Visual C++ 2010 NOT Installed.
IF "%EXIST_ON_ERROR%" == "" PAUSE
)

POPD
ENDLOCAL
EXIST /B
86 changes: 86 additions & 0 deletions dist/install_VS2010_2015.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,86 @@
@ECHO OFF
SETLOCAL ENABLEEXTENSIONS

SET "EXIST_ON_ERROR=%~1"
SET SUCCESS=0

PUSHD %~dp0

@rem Visual Studio 2015
:TRY_2015
SET VCT_PATH=%ProgramFiles(x86)%\MSBuild\Microsoft.Cpp\v4.0\V140\Platforms
IF EXIST "%VCT_PATH%" GOTO FIND_2015
SET VCT_PATH=%ProgramFiles%\MSBuild\Microsoft.Cpp\v4.0\V140\Platforms
IF EXIST "%VCT_PATH%" GOTO FIND_2015
GOTO TRY_2013

:FIND_2015
ECHO VCTargetsPath for Visual Studio 2015: %VCT_PATH%
XCOPY /Q /Y "LLVM" "%VCT_PATH%\..\LLVM\"
XCOPY /Q /Y "LLVM_v140" "%VCT_PATH%\x64\PlatformToolsets\LLVM_v140\"
XCOPY /Q /Y "LLVM_v140_xp" "%VCT_PATH%\x64\PlatformToolsets\LLVM_v140_xp\"
XCOPY /Q /Y "LLVM_v140" "%VCT_PATH%\Win32\PlatformToolsets\LLVM_v140\"
XCOPY /Q /Y "LLVM_v140_xp" "%VCT_PATH%\Win32\PlatformToolsets\LLVM_v140_xp\"
SET SUCCESS=1

@rem Visual Studio 2013
:TRY_2013
SET VCT_PATH=%ProgramFiles(x86)%\MSBuild\Microsoft.Cpp\v4.0\V120\Platforms
IF EXIST "%VCT_PATH%" GOTO FIND_2013
SET VCT_PATH=%ProgramFiles%\MSBuild\Microsoft.Cpp\v4.0\V120\Platforms
IF EXIST "%VCT_PATH%" GOTO FIND_2013
GOTO TRY_2012

:FIND_2013
ECHO VCTargetsPath for Visual Studio 2013: %VCT_PATH%
XCOPY /Q /Y "LLVM" "%VCT_PATH%\..\LLVM\"
XCOPY /Q /Y "LLVM_v120" "%VCT_PATH%\x64\PlatformToolsets\LLVM_v120\"
XCOPY /Q /Y "LLVM_v120_xp" "%VCT_PATH%\x64\PlatformToolsets\LLVM_v120_xp\"
XCOPY /Q /Y "LLVM_v120" "%VCT_PATH%\Win32\PlatformToolsets\LLVM_v120\"
XCOPY /Q /Y "LLVM_v120_xp" "%VCT_PATH%\Win32\PlatformToolsets\LLVM_v120_xp\"
SET SUCCESS=1

@rem Visual Studio 2012
:TRY_2012
SET VCT_PATH=%ProgramFiles(x86)%\MSBuild\Microsoft.Cpp\v4.0\V110\Platforms
IF EXIST "%VCT_PATH%" GOTO FIND_2012
SET VCT_PATH=%ProgramFiles%\MSBuild\Microsoft.Cpp\v4.0\V110\Platforms
IF EXIST "%VCT_PATH%" GOTO FIND_2012
GOTO TRY_2010

:FIND_2012
ECHO VCTargetsPath for Visual Studio 2012: %VCT_PATH%
XCOPY /Q /Y "LLVM" "%VCT_PATH%\..\LLVM\"
XCOPY /Q /Y "x64\LLVM_v110" "%VCT_PATH%\x64\PlatformToolsets\LLVM_v110\"
XCOPY /Q /Y "x64\LLVM_v110_xp" "%VCT_PATH%\x64\PlatformToolsets\LLVM_v110_xp\"
XCOPY /Q /Y "Win32\LLVM_v110" "%VCT_PATH%\Win32\PlatformToolsets\LLVM_v110\"
XCOPY /Q /Y "Win32\LLVM_v110_xp" "%VCT_PATH%\Win32\PlatformToolsets\LLVM_v110_xp\"
SET SUCCESS=1

@rem Visual Studio 2010
:TRY_2010
SET VCT_PATH=%ProgramFiles(x86)%\MSBuild\Microsoft.Cpp\v4.0\Platforms
IF EXIST "%VCT_PATH%" GOTO FIND_2010
SET VCT_PATH=%ProgramFiles%\MSBuild\Microsoft.Cpp\v4.0\Platforms
IF EXIST "%VCT_PATH%" GOTO FIND_2010
GOTO VC_NOT_FOUND

:FIND_2010
ECHO VCTargetsPath for Visual Studio 2010: %VCT_PATH%
XCOPY /Q /Y "LLVM" "%VCT_PATH%\..\LLVM\"
XCOPY /Q /Y "x64\LLVM_v100" "%VCT_PATH%\x64\PlatformToolsets\LLVM_v100\"
XCOPY /Q /Y "Win32\LLVM_v100" "%VCT_PATH%\Win32\PlatformToolsets\LLVM_v100\"
XCOPY /Q /Y "x64\LLVM_v90" "%VCT_PATH%\x64\PlatformToolsets\LLVM_v90\"
XCOPY /Q /Y "Win32\LLVM_v90" "%VCT_PATH%\Win32\PlatformToolsets\LLVM_v90\"
SET SUCCESS=1


:VC_NOT_FOUND
IF %SUCCESS% == 0 (
ECHO Visual C++ 2015, 2013, 2012 or 2010 NOT Installed.
IF "%EXIST_ON_ERROR%" == "" PAUSE
)

POPD
ENDLOCAL
EXIST /B
35 changes: 35 additions & 0 deletions dist/install_VS2012.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
@ECHO OFF
SETLOCAL ENABLEEXTENSIONS

SET "EXIST_ON_ERROR=%~1"
SET SUCCESS=0

PUSHD %~dp0

@rem Visual Studio 2012
:TRY_2012
SET VCT_PATH=%ProgramFiles(x86)%\MSBuild\Microsoft.Cpp\v4.0\V110\Platforms
IF EXIST "%VCT_PATH%" GOTO FIND_2012
SET VCT_PATH=%ProgramFiles%\MSBuild\Microsoft.Cpp\v4.0\V110\Platforms
IF EXIST "%VCT_PATH%" GOTO FIND_2012
GOTO VC_NOT_FOUND

:FIND_2012
ECHO VCTargetsPath for Visual Studio 2012: %VCT_PATH%
XCOPY /Q /Y "LLVM" "%VCT_PATH%\..\LLVM\"
XCOPY /Q /Y "x64\LLVM_v110" "%VCT_PATH%\x64\PlatformToolsets\LLVM_v110\"
XCOPY /Q /Y "x64\LLVM_v110_xp" "%VCT_PATH%\x64\PlatformToolsets\LLVM_v110_xp\"
XCOPY /Q /Y "Win32\LLVM_v110" "%VCT_PATH%\Win32\PlatformToolsets\LLVM_v110\"
XCOPY /Q /Y "Win32\LLVM_v110_xp" "%VCT_PATH%\Win32\PlatformToolsets\LLVM_v110_xp\"
SET SUCCESS=1


:VC_NOT_FOUND
IF %SUCCESS% == 0 (
ECHO Visual C++ 2012 NOT Installed.
IF "%EXIST_ON_ERROR%" == "" PAUSE
)

POPD
ENDLOCAL
EXIST /B
35 changes: 35 additions & 0 deletions dist/install_VS2013.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
@ECHO OFF
SETLOCAL ENABLEEXTENSIONS

SET "EXIST_ON_ERROR=%~1"
SET SUCCESS=0

PUSHD %~dp0

@rem Visual Studio 2013
:TRY_2013
SET VCT_PATH=%ProgramFiles(x86)%\MSBuild\Microsoft.Cpp\v4.0\V120\Platforms
IF EXIST "%VCT_PATH%" GOTO FIND_2013
SET VCT_PATH=%ProgramFiles%\MSBuild\Microsoft.Cpp\v4.0\V120\Platforms
IF EXIST "%VCT_PATH%" GOTO FIND_2013
GOTO VC_NOT_FOUND

:FIND_2013
ECHO VCTargetsPath for Visual Studio 2013: %VCT_PATH%
XCOPY /Q /Y "LLVM" "%VCT_PATH%\..\LLVM\"
XCOPY /Q /Y "LLVM_v120" "%VCT_PATH%\x64\PlatformToolsets\LLVM_v120\"
XCOPY /Q /Y "LLVM_v120_xp" "%VCT_PATH%\x64\PlatformToolsets\LLVM_v120_xp\"
XCOPY /Q /Y "LLVM_v120" "%VCT_PATH%\Win32\PlatformToolsets\LLVM_v120\"
XCOPY /Q /Y "LLVM_v120_xp" "%VCT_PATH%\Win32\PlatformToolsets\LLVM_v120_xp\"
SET SUCCESS=1


:VC_NOT_FOUND
IF %SUCCESS% == 0 (
ECHO Visual C++ 2013 NOT Installed.
IF "%EXIST_ON_ERROR%" == "" PAUSE
)

POPD
ENDLOCAL
EXIST /B
35 changes: 35 additions & 0 deletions dist/install_VS2015.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
@ECHO OFF
SETLOCAL ENABLEEXTENSIONS

SET "EXIST_ON_ERROR=%~1"
SET SUCCESS=0

PUSHD %~dp0

@rem Visual Studio 2015
:TRY_2015
SET VCT_PATH=%ProgramFiles(x86)%\MSBuild\Microsoft.Cpp\v4.0\V140\Platforms
IF EXIST "%VCT_PATH%" GOTO FIND_2015
SET VCT_PATH=%ProgramFiles%\MSBuild\Microsoft.Cpp\v4.0\V140\Platforms
IF EXIST "%VCT_PATH%" GOTO FIND_2015
GOTO VC_NOT_FOUND

:FIND_2015
ECHO VCTargetsPath for Visual Studio 2015: %VCT_PATH%
XCOPY /Q /Y "LLVM" "%VCT_PATH%\..\LLVM\"
XCOPY /Q /Y "LLVM_v140" "%VCT_PATH%\x64\PlatformToolsets\LLVM_v140\"
XCOPY /Q /Y "LLVM_v140_xp" "%VCT_PATH%\x64\PlatformToolsets\LLVM_v140_xp\"
XCOPY /Q /Y "LLVM_v140" "%VCT_PATH%\Win32\PlatformToolsets\LLVM_v140\"
XCOPY /Q /Y "LLVM_v140_xp" "%VCT_PATH%\Win32\PlatformToolsets\LLVM_v140_xp\"
SET SUCCESS=1


:VC_NOT_FOUND
IF %SUCCESS% == 0 (
ECHO Visual C++ 2015 NOT Installed.
IF "%EXIST_ON_ERROR%" == "" PAUSE
)

POPD
ENDLOCAL
EXIST /B
71 changes: 71 additions & 0 deletions dist/make_dist.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
@ECHO OFF

SETLOCAL ENABLEEXTENSIONS
CD /D %~dp0


ECHO Visual Studio 2017 and 2019
@RD /Q /S LLVM_VS2017
XCOPY /Q /S /Y ..\VS2017 LLVM_VS2017\
CALL :SUB_MAKE_ZIP LLVM_VS2017
@RD /Q /S LLVM_VS2017


ECHO Visual Studio 2010 to 2015
@RD /Q /S LLVM_VS2010_2015
XCOPY /Q /Y ..\VS2017\LLVM LLVM_VS2010_2015\LLVM\
XCOPY /Q /S /Y ..\VS2015 LLVM_VS2010_2015\
XCOPY /Q /Y install_VS2010_2015.bat LLVM_VS2010_2015\install.bat*
CALL :SUB_MAKE_ZIP LLVM_VS2010_2015
@RD /Q /S LLVM_VS2010_2015


ECHO Visual Studio 2015
@RD /Q /S LLVM_VS2015
XCOPY /Q /Y ..\VS2017\LLVM LLVM_VS2015\LLVM\
XCOPY /Q /Y ..\VS2015\LLVM_v140 LLVM_VS2015\LLVM_v140\
XCOPY /Q /Y ..\VS2015\LLVM_v140_xp LLVM_VS2015\LLVM_v140_xp\
XCOPY /Q /Y install_VS2015.bat LLVM_VS2015\install.bat*
CALL :SUB_MAKE_ZIP LLVM_VS2015
@RD /Q /S LLVM_VS2015


ECHO Visual Studio 2013
@RD /Q /S LLVM_VS2013
XCOPY /Q /Y ..\VS2017\LLVM LLVM_VS2013\LLVM\
XCOPY /Q /Y ..\VS2015\LLVM_v120 LLVM_VS2013\LLVM_v120\
XCOPY /Q /Y ..\VS2015\LLVM_v120_xp LLVM_VS2013\LLVM_v120_xp\
XCOPY /Q /Y install_VS2013.bat LLVM_VS2013\install.bat*
CALL :SUB_MAKE_ZIP LLVM_VS2013
@RD /Q /S LLVM_VS2013


ECHO Visual Studio 2012
@RD /Q /S LLVM_VS2012
XCOPY /Q /Y ..\VS2017\LLVM LLVM_VS2012\LLVM\
XCOPY /Q /Y ..\VS2015\x64\LLVM_v110 LLVM_VS2012\x64\LLVM_v110\
XCOPY /Q /Y ..\VS2015\x64\LLVM_v110_xp LLVM_VS2012\x64\LLVM_v110_xp\
XCOPY /Q /Y ..\VS2015\Win32\LLVM_v110 LLVM_VS2012\Win32\LLVM_v110\
XCOPY /Q /Y ..\VS2015\Win32\LLVM_v110_xp LLVM_VS2012\Win32\LLVM_v110_xp\
XCOPY /Q /Y install_VS2012.bat LLVM_VS2012\install.bat*
CALL :SUB_MAKE_ZIP LLVM_VS2012
@RD /Q /S LLVM_VS2012


ECHO Visual Studio 2010
@RD /Q /S LLVM_VS2010
XCOPY /Q /Y ..\VS2017\LLVM LLVM_VS2010\LLVM\
XCOPY /Q /Y ..\VS2015\x64\LLVM_v100 LLVM_VS2010\x64\LLVM_v100\
XCOPY /Q /Y ..\VS2015\x64\LLVM_v90 LLVM_VS2010\x64\LLVM_v90\
XCOPY /Q /Y ..\VS2015\Win32\LLVM_v100 LLVM_VS2010\Win32\LLVM_v100\
XCOPY /Q /Y ..\VS2015\Win32\LLVM_v90 LLVM_VS2010\Win32\LLVM_v90\
XCOPY /Q /Y install_VS2010.bat LLVM_VS2010\install.bat*
CALL :SUB_MAKE_ZIP LLVM_VS2010
@RD /Q /S LLVM_VS2010

EXIT /B

:SUB_MAKE_ZIP
7z a -tzip -mx9 "%~1.zip" "%~1" >NUL
ENDLOCAL
EXIT /B
50 changes: 37 additions & 13 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,19 +24,6 @@ or run `VS2017\install.bat` directly (may require Administrator privilege. In Wi

Because `vswhere` doesn't print the installation path for Visual Studio 2019 Preview, please call the script with installation path, e.g: `CALL VS2017\install.bat "C:\Program Files (x86)\Microsoft Visual Studio\2019\Preview"` or call vsdevcmd.bat (or vcvarsall.bat, etc.) before this script.

### Install to AppVeyor Build Image

curl -Ls -o "llvm-utils-master.zip" "https://github.com/zufuliu/llvm-utils/archive/master.zip"
7z x -y "llvm-utils-master.zip" >NUL
CALL "llvm-utils-master\VS2017\install.bat" 1

or

git clone -q --depth=1 --branch=master https://github.com/zufuliu/llvm-utils.git c:\projects\llvm-utils
CALL "c:\projects\llvm-utils\VS2017\install.bat" 1

Please note that LLVM 7.0.0 on AppVeyor doesn't support ARM64.

## LLVM for Visual Studio 2010, 2012, 2013 and 2015
Assume `MB_PATH` is the MSBuild path for Visual C++ (e.g.: `C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0` or `C:\Program Files\MSBuild\Microsoft.Cpp\v4.0`), please manually copy `VS2017\LLVM` and related folders under `VS2015` to following target paths.

Expand Down Expand Up @@ -86,6 +73,43 @@ The Platform Toolset is "LLVM for Visual Studio 2010 (v100)" (`LLVM_v100`) and "
|`VS2015\Win32\LLVM_v100` | `%MB_PATH%\Platforms\Win32\PlatformToolsets\` |
|`VS2015\Win32\LLVM_v90` | `%MB_PATH%\Platforms\Win32\PlatformToolsets\` |

## Install to AppVeyor Build Image
### Install from release archives

| Visual Studio Version | Archive Name |
|------|-------------|
| 2017 and 2019 | LLVM_VS2017.zip |
| 2010 to 2015 | LLVM_VS2010_2015.zip |
| 2015 | LLVM_VS2015.zip |
| 2013 | LLVM_VS2013.zip |
| 2012 | LLVM_VS2012.zip |
| 2010 | LLVM_VS2010.zip |

Examples:

curl -Ls -o "LLVM_VS2017.zip" "https://github.com/zufuliu/llvm-utils/releases/download/v18.12/LLVM_VS2017.zip"
7z x -y "LLVM_VS2017.zip" >NUL
CALL "LLVM_VS2017\install.bat" 1

curl -Ls -o "LLVM_VS2017.zip" "https://github.com/zufuliu/llvm-utils/releases/download/v18.12/LLVM_VS2010_2015.zip"
7z x -y "LLVM_VS2010_2015.zip" >NUL
CALL "LLVM_VS2010_2015\install.bat" 1

### Install from latest master source code

curl -Ls -o "llvm-utils-master.zip" "https://github.com/zufuliu/llvm-utils/archive/master.zip"
7z x -y "llvm-utils-master.zip" >NUL
CALL "llvm-utils-master\VS2017\install.bat" 1
CALL "llvm-utils-master\VS2015\install.bat" 1

or

git clone -q --depth=1 --branch=master https://github.com/zufuliu/llvm-utils.git c:\projects\llvm-utils
CALL "c:\projects\llvm-utils\VS2017\install.bat" 1
CALL "c:\projects\llvm-utils\VS2015\install.bat" 1

Please note that preinstalled LLVM 7.0.0 in AppVeyor build image doesn't support ARM64.

## LLVM Windows Symbolic Link Maker
The huge size of LLVM Windows installation can be reduced dramatically by using Windows symbolic link (see [mklink command](https://docs.microsoft.com/en-us/windows-server/administration/windows-commands/mklink).

Expand Down

0 comments on commit 063afe8

Please sign in to comment.