Skip to content

Commit 534ce29

Browse files
committed
Add GitHub CI
1 parent 6b231da commit 534ce29

File tree

1 file changed

+65
-0
lines changed

1 file changed

+65
-0
lines changed

.github/workflows/pr-tests.yaml

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
name: Pull Request Tests
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- master
7+
types: [opened, synchronize, reopened, ready_for_review]
8+
workflow_dispatch: null
9+
10+
jobs:
11+
gcc:
12+
if: github.event.pull_request.draft == false
13+
permissions:
14+
packages: read
15+
strategy:
16+
fail-fast: false
17+
runs-on: ubuntu-latest
18+
container:
19+
image: ghcr.io/dyninst/amd64/ubuntu-20.04:latest
20+
credentials:
21+
username: ${{ github.actor }}
22+
password: ${{ secrets.github_token }}
23+
24+
name: gcc
25+
steps:
26+
- name: Checkout
27+
uses: actions/checkout@v3
28+
29+
- name: Build
30+
run: |
31+
flags="-DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++"
32+
cmake .. ${flags} -DDyninst_DIR=/dyninst/install/lib/cmake/Dyninst
33+
cmake --build . --parallel 2
34+
35+
- name: Run
36+
run: |
37+
ctest -VV --output-on-failure .
38+
39+
40+
clang:
41+
if: github.event.pull_request.draft == false
42+
permissions:
43+
packages: read
44+
strategy:
45+
fail-fast: false
46+
runs-on: ubuntu-latest
47+
container:
48+
image: ghcr.io/dyninst/amd64/ubuntu-20.04:latest
49+
credentials:
50+
username: ${{ github.actor }}
51+
password: ${{ secrets.github_token }}
52+
name: clang
53+
steps:
54+
- name: Checkout
55+
uses: actions/checkout@v3
56+
57+
- name: Build
58+
run: |
59+
flags="-DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++"
60+
cmake .. ${flags} -DDyninst_DIR=/dyninst/install/lib/cmake/Dyninst
61+
cmake --build . --parallel 2
62+
63+
- name: Run
64+
run: |
65+
ctest -VV --output-on-failure .

0 commit comments

Comments
 (0)