mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-22 02:27:36 +03:00
Library ABI tracking with abigail
Provide two make targets: checkabi and storeabi. storeabi uses libabigail to generate a reference copy of the ABI for the public libraries. checkabi compares such a reference to the compiled version, failing if they are not compatible. No ABI is generated for libzpool.so, it is only used by ztest and zdb and not external consumers. Co-authored-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Antonio Russo <aerusso@aerusso.net> Closes #11144
This commit is contained in:
committed by
Brian Behlendorf
parent
e6c59cd171
commit
14c34c3d49
@@ -0,0 +1,29 @@
|
||||
#
|
||||
# When performing an ABI check the following options are applied:
|
||||
#
|
||||
# --no-unreferenced-symbols: Exclude symbols which are not referenced by
|
||||
# any debug information. Without this _init() and _fini() are incorrectly
|
||||
# reported on CentOS7 for libuutil.so.
|
||||
#
|
||||
# --headers-dir1: Limit ABI checks to public OpenZFS headers, otherwise
|
||||
# changes in public system headers are also reported.
|
||||
#
|
||||
# --suppressions: Honor a suppressions file for each library to provide
|
||||
# a mechanism for suppressing harmless warnings.
|
||||
#
|
||||
|
||||
PHONY += checkabi storeabi
|
||||
|
||||
checkabi:
|
||||
for lib in $(lib_LTLIBRARIES) ; do \
|
||||
abidiff --no-unreferenced-symbols \
|
||||
--headers-dir1 ../../include \
|
||||
--suppressions $${lib%.la}.suppr \
|
||||
$${lib%.la}.abi .libs/$${lib%.la}.so ; \
|
||||
done
|
||||
|
||||
storeabi:
|
||||
cd .libs ; \
|
||||
for lib in $(lib_LTLIBRARIES) ; do \
|
||||
abidw $${lib%.la}.so > ../$${lib%.la}.abi ; \
|
||||
done
|
||||
Reference in New Issue
Block a user