forked from NIWAFisheriesModelling/SPM
-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathazure-pipelines-Linux.yml
74 lines (63 loc) · 2.42 KB
/
azure-pipelines-Linux.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
#####################################################################################
# SPM Ubuntu 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
# USAGE:
#> doBuild.sh [type]
# Valid Build Types:
# help - Print this help page
# check - Do a check of the build system
# boost - Build boost libraries (build this before building the release)
# release - Build standalone release executable
# examples - Build the SPM examples
# documentation - Build the user manual
# rlibrary - Build the R library
# unittests - Run the unit tests
# installer - Build a MS-Windows installer package
# deb - Build the Linux .deb installer
# archive - Build a zipped archive of the application.
# clean - Remove any previous debug/release build information
trigger:
- master
pool:
vmImage: ubuntu-latest
#pool:
# vmImage: 'windows-latest'
steps:
- script: |
sudo apt-get update
sudo apt-get -y install gfortran-7
displayName: "Installing gfortran-7"
- script: |
sudo update-alternatives --remove-all gcc
sudo update-alternatives --remove-all g++
sudo update-alternatives --remove-all gfortran
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-7 10
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-7 10
sudo update-alternatives --install /usr/bin/gfortran gfortran /usr/bin/gfortran-7 10
displayName: "Changing gcc, g++ and gfotran aliases"
- script: |
sudo apt -y install python3 python3-pip
sudo pip3 install pytz
displayName: "Linux: Installing Python3 build environment"
- script: |
sudo apt install texlive-latex-extra
displayName: "Linux: Installing LaTeX build environment"
- script: |
cd BuildSystem
./doBuild.sh boost
displayName: "Linux: Compile BOOST for SPM"
- script: |
cd BuildSystem
./doBuild.sh release
displayName: "Linux: Compile the release version of SPM"
- script: |
cd BuildSystem
./doBuild.sh documentation
displayName: "Linux: Compile the Documentation for SPM"
- script: |
cd BuildSystem
./doBuild.sh unittests
displayName: "Linux: Run the unittests for SPM"