mirror of
git://sourceware.org/git/libabigail.git
synced 2024-12-17 07:24:34 +00:00
The Git repository of the Libabigail Project
ddad560153
The DWARF reader is no longer the only ELF-based reader in libabigail: the CTF reader also operates on ELF files. Other ELF-based formats (such as BTF) may also join in the future. These readers share a lot of similarities: they all operate on object files, they fetch debugging information from certain sections, they rely on the symtab of the read object, the debugging info may be in a separated file (for certain formats) and so on. It follows that a lot of logic can be shared among all the ELF-based readers. This patch is oriented to that direction. A new namespace, abigail::elf_reader, is introduced with the goal of holding features and definitions useful for any ELF-based abigail reader. Then all the definitions related to the status resulting from extracting a corpus from an object file (the dwarf_reader::status) are moved to abigail::elf_reader. The utilities and tests are adjusted accordingly. Signed-off-by: Jose E. Marchesi <jose.marchesi@oracle.com> * include/abg-reader-common.h: New file. * include/abg-dwarf-reader.h (enum status): Move to abg-reader-status.h. (status_to_diagnostic_string): Likewise. (operator|): Likewise. (operator&): Likewise. (operator|=): Likewise. (operator&=): Likewise. Include abg-reader-common.h. * include/Makefile.am (pkginclude_HEADERS): Add abg-elf-reader-common.h. * src/abg-elf-reader-status.cc: New file. * src/abg-dwarf-reader.cc (operator|): Move to abg-elf-reader-common.cc. (operator&): Likewise. (operator|): Likewise. (operator|=): Likewise. (operator&=): Likewise. (status_to_diagnostic_string): Likewise. * src/Makefile.am (libabigail_la_SOURCES): Add elf-reader-common.cc. * src/abg-tools-utils.cc: Use abigail::elf_reader instead of abigail::dwarf_reader for the status definitions. * tools/abicompat.cc: Likewise. * tools/abidiff.cc: Likewise. * tools/abidw.cc: Likewise. * tools/abilint.cc: Likewise. * tools/abipkgdiff.cc: Likewise. * tests/print-diff-tree.cc: Likewise. * tests/test-diff-dwarf.cc: Likewise. * tests/test-read-dwarf.cc: Likewise. * tests/test-symtab.cc: Likewise. * tests/test-ir-walker.cc: Likewise. Signed-off-by: Dodji Seketeli <dodji@redhat.com> |
||
---|---|---|
autoconf-archive | ||
bash-completion | ||
doc | ||
include | ||
m4 | ||
relicensing-scripts | ||
scripts | ||
src | ||
tests | ||
tools | ||
.clang-format | ||
.gitignore | ||
abigail.m4 | ||
ABIXML-FORMAT-VERSIONS | ||
AUTHORS | ||
ChangeLog | ||
COMMIT-LOG-GUIDELINES | ||
COMPILING | ||
configure.ac | ||
CONTRIBUTING | ||
default.abignore | ||
gen-changelog.py | ||
install-sh | ||
libabigail.pc.in | ||
license-change-2020.txt | ||
LICENSE.txt | ||
ltmain.sh | ||
Makefile.am | ||
NEWS | ||
README | ||
release-text-template.txt | ||
update-copyright.sh | ||
VISIBILITY |
This is the Application Binary Interface Generic Analysis and Instrumentation Library. It aims at constructing, manipulating, serializing and de-serializing ABI-relevant artifacts. The set of artifacts that we are intersted is made of quantities like types, variable, fonctions and declarations of a given library or program. For a given library or program this set of quantities is called an ABI corpus. This library aims at (among other things) providing a way to compare two ABI Corpora (apparently the plural of corpus is copora, heh, that's cool), provide detailed information about their differences, and help build tools to infer interesting conclusions about these differences. You are welcome to contribute to this project after reading the files CONTRIBUTING and COMMIT-LOG-GUIDELINES files in the source tree. Communicating with the maintainers of this project -- including sending patches to be include to the source code -- happens via email at libabigail@sourceware.org.