* [Bug default/28976] New: Optionally ignore SONAME when comparing libraries @ 2022-03-17 22:01 woodard at redhat dot com 2022-03-17 22:02 ` [Bug default/28976] " woodard at redhat dot com ` (5 more replies) 0 siblings, 6 replies; 7+ messages in thread From: woodard at redhat dot com @ 2022-03-17 22:01 UTC (permalink / raw) To: libabigail https://sourceware.org/bugzilla/show_bug.cgi?id=28976 Bug ID: 28976 Summary: Optionally ignore SONAME when comparing libraries Product: libabigail Version: unspecified Status: NEW Severity: enhancement Priority: P2 Component: default Assignee: dodji at redhat dot com Reporter: woodard at redhat dot com CC: libabigail at sourceware dot org Target Milestone: --- There are occasional times where you want to compare libraries with abidiff or abicompat for binary compatibility but the SONAME is different. You want the results of the ABI comparison without the SONAME. Please add a option that allows a user to ignors SONAME when comparing libraries or checking for library compatibility. My initial thought is --ignore-soname -- You are receiving this mail because: You are on the CC list for the bug. ^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug default/28976] Optionally ignore SONAME when comparing libraries 2022-03-17 22:01 [Bug default/28976] New: Optionally ignore SONAME when comparing libraries woodard at redhat dot com @ 2022-03-17 22:02 ` woodard at redhat dot com 2022-03-21 14:59 ` woodard at redhat dot com ` (4 subsequent siblings) 5 siblings, 0 replies; 7+ messages in thread From: woodard at redhat dot com @ 2022-03-17 22:02 UTC (permalink / raw) To: libabigail https://sourceware.org/bugzilla/show_bug.cgi?id=28976 Ben Woodard <woodard at redhat dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|dodji at redhat dot com |woodard at redhat dot com -- You are receiving this mail because: You are on the CC list for the bug. ^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug default/28976] Optionally ignore SONAME when comparing libraries 2022-03-17 22:01 [Bug default/28976] New: Optionally ignore SONAME when comparing libraries woodard at redhat dot com 2022-03-17 22:02 ` [Bug default/28976] " woodard at redhat dot com @ 2022-03-21 14:59 ` woodard at redhat dot com 2022-03-21 15:04 ` maennich at android dot com ` (3 subsequent siblings) 5 siblings, 0 replies; 7+ messages in thread From: woodard at redhat dot com @ 2022-03-21 14:59 UTC (permalink / raw) To: libabigail https://sourceware.org/bugzilla/show_bug.cgi?id=28976 --- Comment #1 from Ben Woodard <woodard at redhat dot com> --- Created attachment 14029 --> https://sourceware.org/bugzilla/attachment.cgi?id=14029&action=edit proposed patch RFC what do you think of this patch to add this feature. -- You are receiving this mail because: You are on the CC list for the bug. ^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug default/28976] Optionally ignore SONAME when comparing libraries 2022-03-17 22:01 [Bug default/28976] New: Optionally ignore SONAME when comparing libraries woodard at redhat dot com 2022-03-17 22:02 ` [Bug default/28976] " woodard at redhat dot com 2022-03-21 14:59 ` woodard at redhat dot com @ 2022-03-21 15:04 ` maennich at android dot com 2022-03-21 19:21 ` woodard at redhat dot com ` (2 subsequent siblings) 5 siblings, 0 replies; 7+ messages in thread From: maennich at android dot com @ 2022-03-21 15:04 UTC (permalink / raw) To: libabigail https://sourceware.org/bugzilla/show_bug.cgi?id=28976 Matthias Maennich <maennich at android dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |maennich at android dot com --- Comment #2 from Matthias Maennich <maennich at android dot com> --- I think it makes sense to send this patch to the list for review. The hunk + if(ctxt->show_soname_change()) + r->priv_->sonames_equal_ = f->get_soname() == s->get_soname(); + else + r->priv_->sonames_equal_ = true; can be written as + r->priv_->sonames_equal_ = ! ctxt->show_soname_change() || f->get_soname() == s->get_soname(); -- You are receiving this mail because: You are on the CC list for the bug. ^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug default/28976] Optionally ignore SONAME when comparing libraries 2022-03-17 22:01 [Bug default/28976] New: Optionally ignore SONAME when comparing libraries woodard at redhat dot com ` (2 preceding siblings ...) 2022-03-21 15:04 ` maennich at android dot com @ 2022-03-21 19:21 ` woodard at redhat dot com 2022-03-31 21:33 ` woodard at redhat dot com 2022-06-28 22:28 ` woodard at redhat dot com 5 siblings, 0 replies; 7+ messages in thread From: woodard at redhat dot com @ 2022-03-21 19:21 UTC (permalink / raw) To: libabigail https://sourceware.org/bugzilla/show_bug.cgi?id=28976 --- Comment #3 from Ben Woodard <woodard at redhat dot com> --- (In reply to Matthias Maennich from comment #2) > The hunk > > + if(ctxt->show_soname_change()) > + r->priv_->sonames_equal_ = f->get_soname() == s->get_soname(); > + else > + r->priv_->sonames_equal_ = true; > > can be written as > > + r->priv_->sonames_equal_ = ! ctxt->show_soname_change() > || f->get_soname() == s->get_soname(); That is clever. It might just be me but I find my version easier to read and I doubt with optimization that the resulting machine code is going to be much different. We should only be passing through this code once per execution and so even if it isn't -- oh well. I also considered: r->priv_->sonames_equal_ = ctxt->show_soname_change() ? f->get_soname() == s->get_soname() : true; and yours is a more compact form of that. -- You are receiving this mail because: You are on the CC list for the bug. ^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug default/28976] Optionally ignore SONAME when comparing libraries 2022-03-17 22:01 [Bug default/28976] New: Optionally ignore SONAME when comparing libraries woodard at redhat dot com ` (3 preceding siblings ...) 2022-03-21 19:21 ` woodard at redhat dot com @ 2022-03-31 21:33 ` woodard at redhat dot com 2022-06-28 22:28 ` woodard at redhat dot com 5 siblings, 0 replies; 7+ messages in thread From: woodard at redhat dot com @ 2022-03-31 21:33 UTC (permalink / raw) To: libabigail https://sourceware.org/bugzilla/show_bug.cgi?id=28976 Ben Woodard <woodard at redhat dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |27019 Referenced Bugs: https://sourceware.org/bugzilla/show_bug.cgi?id=27019 [Bug 27019] BUILD metabug -- You are receiving this mail because: You are on the CC list for the bug. ^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug default/28976] Optionally ignore SONAME when comparing libraries 2022-03-17 22:01 [Bug default/28976] New: Optionally ignore SONAME when comparing libraries woodard at redhat dot com ` (4 preceding siblings ...) 2022-03-31 21:33 ` woodard at redhat dot com @ 2022-06-28 22:28 ` woodard at redhat dot com 5 siblings, 0 replies; 7+ messages in thread From: woodard at redhat dot com @ 2022-06-28 22:28 UTC (permalink / raw) To: libabigail https://sourceware.org/bugzilla/show_bug.cgi?id=28976 Ben Woodard <woodard at redhat dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #4 from Ben Woodard <woodard at redhat dot com> --- This patch has been merged. commit c7a71ba2d146d4253d96d27150a741bc3290d275 Author: Ben Woodard <woodard@redhat.com> Date: Wed May 4 10:42:29 2022 -0700 Add an option ignore SONAME differences in libraries There are rare use cases where we do not want to compare the SONAME when testing libraries for compatiblity or diffing libraries. This adds an option to ignore the SONAME when doing the comparison. In these cases, we will edit the application's DT_NEEDED to point to the other library. This reuses the show_soname_change() function and slightly changes its meaning to not only control if the sonames are printed but also if they are compared. There didn't seem to be any other users of this function and slight semantic change seemed harmless. * doc/manuals/abicompat.rst - added new option * doc/manuals/abidiff.rst - added new option to manpage * src/abg-comparison.cc (compute_diff): don't bother comparing the sonames if you aren't going to print them. * tools/abicompat.cc (options::ignore_soname): Add new data member. (parse_command_line): Support the new --ignore-soname command line option. (display_usage): Add a description string for the new --ignore-soname command line option. (create_diff_context): Set the diff_context::show_soname_change from the new options::ignore_soname data member. * tools/abidiff.cc (options::ignore_soname): Add new data member. (display_usage): Add a description string for the new --ignore-soname command line option. (parse_command_line): Support the new --ignore-soname command line option. (set_diff_context_from_opts): Set the diff_context::show_soname_change from the new options::ignore_soname. Signed-off-by: Ben Woodard <woodard@redhat.com> Signed-off-by: Dodji Seketeli <dodji@redhat.com> -- You are receiving this mail because: You are on the CC list for the bug. ^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2022-06-28 22:28 UTC | newest] Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2022-03-17 22:01 [Bug default/28976] New: Optionally ignore SONAME when comparing libraries woodard at redhat dot com 2022-03-17 22:02 ` [Bug default/28976] " woodard at redhat dot com 2022-03-21 14:59 ` woodard at redhat dot com 2022-03-21 15:04 ` maennich at android dot com 2022-03-21 19:21 ` woodard at redhat dot com 2022-03-31 21:33 ` woodard at redhat dot com 2022-06-28 22:28 ` woodard at redhat dot com
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).