libabigail/tools
Dodji Seketeli edfe5a1dec abipkgdiff: Add a new --self-check option
After the report of
https://sourceware.org/bugzilla/show_bug.cgi?id=26769 it became
apparent that we want to be able compare a binary against its ABIXML
representation, including for cases where the binaries are embedded in
RPM packages.

This patches thus introduces the --self-check option to abipkgdiff so
that it can be invoked like this:

    $ abipkgdiff --self-check --d1 libstdc++-debuginfo-10.2.1-8.fc34.x86_64.rpm --d1 gcc-debuginfo-10.2.1-8.fc34.x86_64.rpm libstdc++-10.2.1-8.fc34.x86_64.rpm

    ==== SELF CHECK SUCCEEDED for 'libstdc++.so.6.0.28'====
    $

With this option, libabigail compares each binary in the RPM against
its own ABIXML representation.

This should hopefully help to write regression tests which have as
sole inputs the links to download the RPMs.  It's also useful to ease
the process of reproducing the issue raised.

This option can now be used, for instance, by the libabigail-selfcheck
program over at https://pagure.io/libabigail-selfcheck.

	* tools/abipkgdiff.cc (options::self_check): Define new data
	member.
	(options::options): Initialize it.
	(display_usage): Add help string for the --self-check option.
	(parse_command): Parse the new --self-check option.
	(extract_deb): Add missing newline.
	(compare): Remove useless white space.
	(compare_to_self, self_compare_prepared_userspace_package)
	(self_compare_prepared_package, compare_to_self): Add new static
	functions.
	(class self_compare_task): Add new class.
	(prepare_package): Add a new overload that takes just one
	parameter.
	(elf_size_is_greater): Don't crash if the args are empty.
	(main): If the --self-check option is given, make sure we have
	just one package in argument.  Use the new compare_to_self
	function to handle the --self-check option.
	* doc/manuals/abipkgdiff.rst: Add documentation for the new
	--self-check option.

Signed-off-by: Dodji Seketeli <dodji@redhat.com>
2020-11-23 17:50:05 +01:00
..
.gitignore Update .gitignore files to ignore typical dev side products 2019-04-16 16:32:52 +02:00
abiar.cc Update copyright year to 2020 2020-02-21 17:05:01 +01:00
abicompat.cc Fix HARMLESS_SYMBOL_ALIAS_CHANGE_CATEGORY spelling 2020-06-11 10:06:04 +02:00
abidiff.cc Make abidiff and abidw support several --headers-dir{1,2} options 2020-09-18 10:27:18 +02:00
abidw.cc Make abidiff and abidw support several --headers-dir{1,2} options 2020-09-18 10:27:18 +02:00
abilint.cc Add --header-file option to add individual public header files. 2020-04-14 17:17:28 +02:00
abipkgdiff.cc abipkgdiff: Add a new --self-check option 2020-11-23 17:50:05 +01:00
abisym.cc abisym: Remove leading space in output. 2020-03-10 18:03:03 +01:00
binilint.cc Update copyright year to 2020 2020-02-21 17:05:01 +01:00
fedabipkgdiff Bug 22722 - Make fedabipkgdiff and its tests support both python 3 and 2 2018-03-29 13:46:50 +02:00
kmidiff.cc Update copyright year to 2020 2020-02-21 17:05:01 +01:00
Makefile.am Support loading and comparing two kernel trees 2017-07-03 17:45:36 +02:00