commit | f266e9c8e7b5778b8d215a5f52421487bfae3fec | [log] [tgz] |
---|---|---|
author | Sid Nayyar <sidnayyar@google.com> | Mon Jan 30 17:55:34 2023 +0000 |
committer | Matthias Maennich <maennich@google.com> | Wed Feb 01 12:07:46 2023 +0000 |
tree | 9f27678baf2b8be96515da8937dfcef0edf9cc37 | |
parent | bd5e72db5f0c89f38a2f3aa40dbdf9c946bf3f5f [diff] |
fidelity: Exclude anonymous structs/unions/enums from fidelity diff Fidelity monitoring of anonymous structs/unions/enums is not very useful. This change gets rid of such anonymous types from the fidelity diff and therefore the fidelity diff report. PiperOrigin-RevId: 505722877 Change-Id: Ib2bb17f7ed3faa5f8f13dfed4d5ad93799fb7737
The STG (symbol-type graph) is an ABI representation and this project contains tools for the creation and comparison of such representations. At present parsers exist for libabigail's ABI XML (C types only) and BTF. The ABI diff tool, stgdiff, supports multiple reporting options.
This software currently depends on libxml2 for XML parsing, on libelf to find .BTF sections and on Linux UAPI headers for BTF types.
To build from source, you will need a few dependencies:
Debian | RedHat |
---|---|
libelf-dev | elfutils-devel |
libxml2-dev | libxml2-devel |
linux-libc-dev | kernel-headers |
Instructions are included for local and Docker builds.
You can build as follows:
$ make
A Dockerfile is provided to build a container with libabigail to easily compile the STG tools:
$ docker build -t stg .
And then enter the container:
$ docker run -it stg
If you want to bind your development code to the container:
$ docker run -it $PWD:/src -it stg
The source code is added to /src
, so when your code is bound you can edit on your host and re-compile in the container.
Note that the Dockerfile can provide a development environment (non multi-stage build with the source code) or a production image (a multi-stage build with only the final binary). By default we provide the first, and you can uncomment the final lines of the file for the latter.
See CONTRIBUTING.md for details.