Skip to content

Commit 1e0f843

Browse files
committed
libclang-abi-tests: Fix failure when checking libclang.so
We were assuming that the symbol versions for libclang.so would be different for each major release, but this is not longer true. The libclang.so symbol versions only change when the ABI changes.
1 parent 2bae96d commit 1e0f843

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

.github/workflows/libclang-abi-tests.yml

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -117,10 +117,12 @@ jobs:
117117
- name: Dump ABI
118118
run: |
119119
parallel abi-dumper -lver ${{ matrix.ref }} -skip-cxx -public-headers ./install/include/${{ needs.abi-dump-setup.outputs.ABI_HEADERS }} -o {}-${{ matrix.ref }}.abi ./build/lib/{} ::: ${{ needs.abi-dump-setup.outputs.ABI_LIBS }}
120-
for lib in ${{ needs.abi-dump-setup.outputs.ABI_LIBS }}; do
121-
# Remove symbol versioning from dumps, so we can compare across major versions.
122-
sed -i 's/LLVM_${{ matrix.llvm_version_major }}/LLVM_NOVERSION/' $lib-${{ matrix.ref }}.abi
123-
done
120+
# Remove symbol versioning from dumps, so we can compare across major
121+
# versions. We don't need to do this for libclang.so since its ABI
122+
# is stable across major releases and the symbol versions don't change.
123+
if [ -e libclang-cpp.so-${{ matrix.ref }}.abi ]; then
124+
sed -i 's/LLVM_[0-9]\+/LLVM_NOVERSION/' libclang-cpp.so-${{ matrix.ref }}.abi
125+
fi
124126
- name: Upload ABI file
125127
uses: actions/upload-artifact@v2
126128
with:

0 commit comments

Comments
 (0)