forked from aziomq/aziomq
-
Notifications
You must be signed in to change notification settings - Fork 108
81 lines (76 loc) · 2.05 KB
/
cmake.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
name: CMake
on:
push:
branches:
- '**'
pull_request:
branches: [master]
jobs:
build:
strategy:
fail-fast: false
matrix:
config:
- {
name: "ubuntu22",
os: ubuntu-22.04,
boost_url: system,
zmq_tag: system,
system_packages: "libboost-all-dev libzmq3-dev ",
cc: "gcc",
cxx: "g++",
}
- {
name: "ubuntu20 stock",
os: ubuntu-20.04,
boost_url: system,
zmq_tag: system,
system_packages: "libboost-all-dev libzmq3-dev ",
cc: "gcc",
cxx: "g++",
}
- {
name: "macos12 ",
os: macos-12,
boost_url: system,
zmq_tag: system,
system_packages: "zmq boost",
cc: "clang",
cxx: "clang++",
}
- {
name: "macos11 ",
os: macos-11,
boost_url: system,
zmq_tag: system,
system_packages: "zmq boost",
cc: "clang",
cxx: "clang++",
}
runs-on: ${{ matrix.config.os }}
env:
CC: ${{ matrix.config.cc }}
CXX: ${{ matrix.config.cxx }}
CTEST_OUTPUT_ON_FAILURE: 1
PACKAGES: ${{ matrix.config.system_packages }}
steps:
- uses: actions/checkout@v3
- name: buildtools on ubuntu
if: startsWith(matrix.config.name, 'ubuntu')
shell: bash
run: |
if [ -n "$PACKAGES" ]; then
sudo apt-get install -y $PACKAGES
fi
- name: buildtools on macos
if: startsWith(matrix.config.name, 'macos') && matrix.config.*.system_packages
shell: bash
run: |
if [ -n "$PACKAGES" ]; then
brew install $PACKAGES
fi
- name: build
shell: bash
run: |
cmake -DBOOST_URL=${{matrix.config.boost_url}} -DZMQ_TAG=${{matrix.config.zmq_tag}} -S .github/workflows/cmake-superbuild -B build
cmake --build build