forked from REGoth-project/REGoth-bs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathazure-pipelines.yml
134 lines (119 loc) · 3.86 KB
/
azure-pipelines.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
# Starter pipeline
# Start with a minimal pipeline that you can customize to build and deploy your code.
# Add steps that build, run tests, deploy, and more:
# https://aka.ms/yaml
trigger:
- master
# We can run multiple jobs in parallel. For this project
# I'm running Linux, Windows, and macOS jobs. For syntac details
# see https://docs.microsoft.com/en-us/azure/devops/pipelines/process/phases
jobs:
- job: Linux
# The VM image to use for the hosted agent. For a list of possible agents
# see https://docs.microsoft.com/en-us/azure/devops/pipelines/agents/hosted
# You can see the software installed on each agent at the same link.
pool:
vmImage: 'ubuntu-16.04'
steps:
- task: Bash@3
displayName: Install Packages via apt-get
inputs:
targetType: 'inline'
script: |
set -e
sudo apt-get update
sudo add-apt-repository ppa:ubuntu-toolchain-r/test
sudo apt-get install uuid-dev libgl1-mesa-dev libglu1-mesa-dev mesa-common-dev libx11-dev libxcursor-dev libxrandr-dev libxi-dev gcc-8 g++-8
#cmake
#TODO: remove if newer cmake version is available upstream. See: https://github.com/microsoft/azure-pipelines-image-generation/issues/1097
sudo rm /usr/local/bin/ccmake* /usr/local/bin/cmake* /usr/local/bin/cpack* /usr/local/bin/ctest*
sudo apt-get install apt-transport-https ca-certificates gnupg software-properties-common wget
wget -O - https://apt.kitware.com/keys/kitware-archive-latest.asc 2>/dev/null | sudo apt-key add -
sudo apt-add-repository 'deb https://apt.kitware.com/ubuntu/ xenial main'
sudo apt-get update
sudo apt-get install cmake
- task: Bash@3
displayName: Build REGoth
inputs:
targetType: 'inline'
script: |
set -e
export CC=gcc-8
export CXX=g++-8
cd ci
./build-linux.sh
- task: Bash@3
displayName: List build directory
inputs:
targetType: 'inline'
script: |
set -e
cd ci
find build/
- task: Bash@3
displayName: Gather build artifacts
inputs:
targetType: 'inline'
script: |
set -e
cd ci
./pack-release-linux.sh
find artifacts/
- task: CopyFiles@2
inputs:
contents: 'ci/artifacts\**'
targetFolder: $(Build.ArtifactStagingDirectory)
- task: PublishBuildArtifacts@1
inputs:
pathtoPublish: $(Build.ArtifactStagingDirectory)
artifactName: REGoth-ci-bin
# - job: macOS
# pool:
# vmImage: 'macOS-10.14'
# steps:
# - bash: |
# brew install ossp-uuid
# brew install gcc-8
# export CC=gcc-8
# export CXX=g++-8
# mkdir build
# cd build
# cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo ..
# cmake --build . --parallel
- job: Windows
pool:
vmImage: 'vs2017-win2016'
steps:
- task: Bash@3
displayName: Build REGoth
inputs:
targetType: 'inline'
script: |
set -e
cd ci
./build-windows.sh
- task: Bash@3
displayName: List build directory
inputs:
targetType: 'inline'
script: |
set -e
cd ci
find build/
- task: Bash@3
displayName: Gather build artifacts
inputs:
targetType: 'inline'
script: |
set -e
cd ci
./pack-release-windows.sh
find artifacts/
- task: CopyFiles@2
inputs:
contents: 'ci/artifacts\**'
targetFolder: $(Build.ArtifactStagingDirectory)
- task: PublishBuildArtifacts@1
inputs:
pathtoPublish: $(Build.ArtifactStagingDirectory)
artifactName: REGoth-ci-bin