CI: Enable a macOS job
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
diff --git a/.azure-pipelines/steps/dependencies-macos.yml b/.azure-pipelines/steps/dependencies-macos.yml
new file mode 100644
index 0000000..a7efc4a
--- /dev/null
+++ b/.azure-pipelines/steps/dependencies-macos.yml
@@ -0,0 +1,9 @@
+---
+steps:
+ - bash: |
+ brew install meson doxygen bison
+ brew link bison --force
+ displayName: 'Dependencies (macOS)'
+ env:
+ HOMEBREW_NO_AUTO_UPDATE: 1
+ HOMEBREW_NO_INSTALL_CLEANUP: 1
diff --git a/.azure-pipelines/steps/meson.yml b/.azure-pipelines/steps/meson.yml
index b2a44c5..bb25197 100644
--- a/.azure-pipelines/steps/meson.yml
+++ b/.azure-pipelines/steps/meson.yml
@@ -1,10 +1,15 @@
---
parameters:
options: ""
+ wrapper: ""
workdir: "meson-build"
steps:
- - bash: meson setup '${{ parameters.workdir }}' ${{ parameters.options }}
+ - bash: |
+ if [[ -x /usr/local/opt/bison/bin/bison ]] ; then
+ export PATH="/usr/local/opt/bison/bin:${PATH}"
+ fi
+ meson setup '${{ parameters.workdir }}' ${{ parameters.options }}
displayName: 'Configuration (Meson)'
- bash: ninja
displayName: 'Build (Meson)'
@@ -12,8 +17,7 @@ steps:
env:
TERM: dumb
- bash: |
- meson test --print-errorlogs \
- --wrap='valgrind --leak-check=full --track-origins=yes --error-exitcode=99'
+ meson test --print-errorlogs --wrap='${{ parameters.wrapper }}'
displayName: 'Tests (Meson)'
workingDirectory: ${{ parameters.workdir }}
- bash: |
diff --git a/azure-pipelines.yml b/azure-pipelines.yml
index ca9bff5..70b4881 100644
--- a/azure-pipelines.yml
+++ b/azure-pipelines.yml
@@ -12,6 +12,7 @@ jobs:
- template: .azure-pipelines/steps/meson.yml
parameters:
options: -Denable-wayland=false
+ wrapper: valgrind --leak-check=full --track-origins=yes --error-exitcode=99
- job: 'Autotools'
dependsOn: []
pool:
@@ -19,3 +20,12 @@ jobs:
steps:
- template: .azure-pipelines/steps/dependencies-linux.yml
- template: .azure-pipelines/steps/autotools.yml
+ - job: 'macOS'
+ dependsOn: []
+ pool:
+ vmImage: 'macos-10.13'
+ steps:
+ - template: .azure-pipelines/steps/dependencies-macos.yml
+ - template: .azure-pipelines/steps/meson.yml
+ parameters:
+ options: -Denable-wayland=false -Denable-x11=false