-
Notifications
You must be signed in to change notification settings - Fork 59
122 lines (120 loc) · 4.01 KB
/
Copy pathabi-stable.yaml
File metadata and controls
122 lines (120 loc) · 4.01 KB
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
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
name: check-abi for stable branch
on:
push:
branches:
- 'stable-*'
paths:
- '.github/workflows/abi-stable.yaml'
- '**.h'
- '**.c'
- '**.version'
pull_request:
branches:
- 'stable-*'
workflow_dispatch:
jobs:
reference-abi:
runs-on: ubuntu-24.04
steps:
- name: get parent tag (push)
run: >
echo ${{ github.ref }} |
sed -E 's,refs/heads/stable-([0-9]\.[0-9]*)\.y,PARENT_TAG=\1.0,' >> $GITHUB_ENV
if: github.event_name == 'push'
- name: get parent tag (PR)
run: >
echo ${{ github.base_ref }} |
sed -E 's,stable-([0-9]\.[0-9]*)\.y,PARENT_TAG=\1.0,' >> $GITHUB_ENV
if: github.event_name == 'pull_request'
- name: assert parent tag
run: /bin/false
if: env.PARENT_TAG == ''
- name: try to download ABI for ${{ env.PARENT_TAG }}
id: download_abi
continue-on-error: true
uses: dawidd6/action-download-artifact@v21
with:
workflow: abi-stable.yaml
workflow_conclusion: ''
branch: ${{ github.ref_name }}
name: multipath-abi-${{ env.PARENT_TAG }}
search_artifacts: true
path: __unused__
- name: update
if: steps.download_abi.outcome != 'success'
run: sudo apt-get update
- name: dependencies
if: steps.download_abi.outcome != 'success'
run: >
sudo apt-get install --yes gcc
gcc make pkg-config abigail-tools
libdevmapper-dev libreadline-dev libaio-dev libsystemd-dev
libudev-dev libjson-c-dev liburcu-dev libcmocka-dev libedit-dev
libmount-dev
- name: checkout ${{ env.PARENT_TAG }}
if: steps.download_abi.outcome != 'success'
uses: actions/checkout@v7
with:
ref: ${{ env.PARENT_TAG }}
- name: build ABI for ${{ env.PARENT_TAG }}
if: steps.download_abi.outcome != 'success'
run: make -j$(nproc) -Orecurse abi
- name: save ABI
if: steps.download_abi.outcome != 'success'
uses: actions/upload-artifact@v7
with:
name: multipath-abi-${{ env.PARENT_TAG }}
path: abi
check-abi:
runs-on: ubuntu-24.04
needs: reference-abi
steps:
- name: get parent tag (push)
run: >
echo ${{ github.ref }} |
sed -E 's,refs/heads/stable-([0-9]\.[0-9]*)\.y,PARENT_TAG=\1.0,' >> $GITHUB_ENV
if: github.event_name == 'push'
- name: get parent tag (PR)
run: >
echo ${{ github.base_ref }} |
sed -E 's,stable-([0-9]\.[0-9]*)\.y,PARENT_TAG=\1.0,' >> $GITHUB_ENV
if: github.event_name == 'pull_request'
- name: assert parent tag
run: /bin/false
if: env.PARENT_TAG == ''
- name: checkout ${{ github.ref }}
uses: actions/checkout@v7
with:
ref: ${{ github.ref }}
- name: download ABI for ${{ env.PARENT_TAG }}
id: download_abi
uses: dawidd6/action-download-artifact@v21
with:
workflow: abi-stable.yaml
workflow_conclusion: ''
branch: ${{ github.ref_name }}
name: multipath-abi-${{ env.PARENT_TAG }}
search_artifacts: true
path: reference-abi
- name: update
run: sudo apt-get update
- name: dependencies
run: >
sudo apt-get install --yes gcc
gcc make pkg-config abigail-tools
libdevmapper-dev libreadline-dev libaio-dev libsystemd-dev
libudev-dev libjson-c-dev liburcu-dev libcmocka-dev libedit-dev
libmount-dev
- name: check ABI of ${{ github.ref }} against ${{ env.PARENT_TAG }}
id: check_abi
run: make -j$(nproc) -Orecurse abi-test
continue-on-error: true
- name: save differences
if: steps.check_abi.outcome != 'success'
uses: actions/upload-artifact@v7
with:
name: abi-test
path: abi-test
- name: fail
run: /bin/false
if: steps.check_abi.outcome != 'success'