Skip to content

Commit 49b7ab1

Browse files
authored
Add CI step to check changes in the exported ABI (GH-25232)
1 parent 20d56bd commit 49b7ab1

File tree

3 files changed

+16046
-0
lines changed

3 files changed

+16046
-0
lines changed

.github/workflows/build.yml

+22
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,28 @@ jobs:
4141
git diff --name-only origin/$GITHUB_BASE_REF.. | grep -qvE '(\.rst$|^Doc|^Misc)' && echo '::set-output name=run_tests::true' || true
4242
fi
4343
44+
check_abi:
45+
name: 'Check if the ABI has changed'
46+
runs-on: ubuntu-20.04
47+
needs: check_source
48+
if: needs.check_source.outputs.run_tests == 'true'
49+
steps:
50+
- uses: actions/checkout@v2
51+
- uses: actions/setup-python@v2
52+
- name: Install Dependencies
53+
run: |
54+
sudo ./.github/workflows/posix-deps-apt.sh
55+
sudo apt-get install -yq abigail-tools
56+
- name: Build CPython
57+
env:
58+
CFLAGS: -g3 -O0
59+
run: |
60+
# Build Python with the libpython dynamic library
61+
./configure --enable-shared
62+
make -j4
63+
- name: Check for changes in the ABI
64+
run: make check-abidump
65+
4466
check_generated_files:
4567
name: 'Check if generated files are up to date'
4668
runs-on: ubuntu-latest

0 commit comments

Comments
 (0)