Skip to content
This repository was archived by the owner on Dec 20, 2019. It is now read-only.

Commit 0529540

Browse files
committed
Add AppVeyor for experimental release building
1 parent 80990c3 commit 0529540

File tree

1 file changed

+71
-0
lines changed

1 file changed

+71
-0
lines changed

appveyor.yml

Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
#---------------------------------#
2+
# general configuration #
3+
#---------------------------------#
4+
5+
#version: 1.0.{build}-{branch}
6+
7+
#---------------------------------#
8+
# environment configuration #
9+
#---------------------------------#
10+
11+
environment:
12+
matrix:
13+
- APPVEYOR_JOB_ARCH: x64
14+
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
15+
- APPVEYOR_JOB_ARCH: x86
16+
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
17+
18+
# scripts that are called at very beginning, before repo cloning
19+
init:
20+
- git config --global core.autocrlf input
21+
22+
clone_depth: 1
23+
24+
# scripts that run after cloning repository
25+
install:
26+
- cd c:\projects
27+
# Fetch submodules
28+
- cd llvm
29+
- git submodule update --init --recursive
30+
- cd ..
31+
# Download & extract Ninja
32+
- appveyor DownloadFile "https://github.com/ninja-build/ninja/releases/download/v1.8.2/ninja-win.zip" -FileName ninja.zip
33+
- md ninja
34+
- cd ninja
35+
- 7z x ..\ninja.zip > nul
36+
- cd ..
37+
# Set environment variables
38+
- set PATH=%CD%\ninja;%PATH%
39+
- if "%APPVEYOR_BUILD_WORKER_IMAGE:~-4%" == "2017" call "C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\Tools\VsDevCmd.bat" -arch=%APPVEYOR_JOB_ARCH%
40+
- if "%APPVEYOR_BUILD_WORKER_IMAGE:~-4%" == "2015" call "C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\vcvarsall.bat" %APPVEYOR_JOB_ARCH%
41+
# Print environment info
42+
- set
43+
- msbuild /version
44+
- cl
45+
- cmake --version
46+
- ninja --version
47+
48+
#---------------------------------#
49+
# build configuration #
50+
#---------------------------------#
51+
52+
build_script:
53+
- cd c:\projects
54+
- md ninja-llvm
55+
- cd ninja-llvm
56+
- cmake -G Ninja -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=c:\projects\LLVM-%APPVEYOR_JOB_ARCH% -DLLVM_USE_CRT_RELEASE=MT -DLLVM_TARGETS_TO_BUILD=X86;AArch64;ARM;PowerPC;NVPTX ..\llvm
57+
- ninja -j3 install
58+
59+
after_build:
60+
# compress installation dir & publish as artifact
61+
- ps: |
62+
echo 'Preparing artifact...'
63+
cd "c:\projects\LLVM-$Env:APPVEYOR_JOB_ARCH"
64+
del bin\ld.lld.exe
65+
del bin\lld.exe
66+
$artifactFilename = "LLVM-$Env:APPVEYOR_JOB_ARCH.7z"
67+
7z a "..\$artifactFilename" * > $null
68+
cd ..
69+
Push-AppveyorArtifact $artifactFilename
70+
71+
test: off

0 commit comments

Comments
 (0)