-
Notifications
You must be signed in to change notification settings - Fork 10
45 lines (43 loc) · 1.43 KB
/
build.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
name: Build and test
on: [pull_request]
jobs:
linux:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install boost (and curl for ppconsul)
run: |
sudo apt-get update
sudo apt-get install -yq libcurl4-openssl-dev libboost-system1.74-dev libboost-test1.74-dev libboost-program-options1.74-dev
- name: Install ppconsul
run: |
set -x
git clone https://github.com/oliora/ppconsul.git
mkdir ppconsul_install; mkdir ppconsul/build
cd ppconsul/build
cmake .. -DCMAKE_INSTALL_PREFIX=$GITHUB_WORKSPACE/ppconsul_install && make -j install
- name: Run CMake
run: mkdir build && cd build && cmake .. -Dppconsul_DIR=$GITHUB_WORKSPACE/ppconsul_install/cmake
- name: Build project
run: cd build && make -j
- name: Test
run: cd build && make test
macos:
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- name: Install boost
run: brew install boost
- name: Install ppconsul
run: |
set -x
git clone https://github.com/oliora/ppconsul.git
mkdir ppconsul_install; mkdir ppconsul/build
cd ppconsul/build
cmake .. -DCMAKE_INSTALL_PREFIX=$GITHUB_WORKSPACE/ppconsul_install && make -j install
- name: Run CMake
run: mkdir build && cd build && cmake ..
- name: Build project
run: cd build && make -j
- name: Test
run: cd build && make test