This bug has been migrated to another issue tracking site. It has been closed here and may no longer be being monitored.

If you would like to get updates for this issue, or to participate in it, you may do so at Red Hat Issue Tracker .
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 2158104 - abidiff claims false error
Summary: abidiff claims false error
Keywords:
Status: CLOSED MIGRATED
Alias: None
Product: Red Hat Enterprise Linux 9
Classification: Red Hat
Component: libabigail
Version: 9.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: ---
Assignee: Dodji Seketeli
QA Contact: Martin Cermak
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2023-01-04 08:58 UTC by Milan Crha
Modified: 2023-09-22 15:56 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2023-09-22 15:56:29 UTC
Type: Bug
Target Upstream Version:
Embargoed:
pm-rhel: mirror+


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker   RHEL-7321 0 None Migrated None 2023-09-22 15:56:23 UTC
Red Hat Issue Tracker RHELPLAN-143728 0 None None None 2023-01-04 09:00:54 UTC

Description Milan Crha 2023-01-04 08:58:24 UTC
This rpminspect run:

http://artifacts.osci.redhat.com/testing-farm/2619f406-62b2-4ab4-a3bd-beac57ec2c63/work-rpminspect58e89i9t/rpminspect/execute/data/rpminspect/

related to:

https://dashboard.osci.redhat.com/#/artifact/brew-build/aid/49864849

claims an error in an abidiff test. When looking into it, the abidiff claims a structure size change of an EMailDisplayPrivate structure (which is expected, due to added patch), but this structure is declared inside e-mail-display.c and it is not accessible from anywhere else, thus this is not an ABI change by any means.

According to the rpminspect logs there had been used abidiff version 2.2.0.

Comment 1 Dodji Seketeli 2023-01-10 13:17:50 UTC
Thank you Milan for taking the time to report this problem.

I looked into it and you are right, abidiff is reporting an type change on the EMailDisplayPrivate structure.

This is how I reproduced it, by invoking abidiff on the content of the two RPMs evolution-3.40.4-6.el9.x86_64.rpm, evolution-3.40.4-9.el9.x86_64.rpm and their associated debuginfo *AND* devel packages extracted in two directories named evolution-3.40.4-6.el9.x86_64 and evolution-3.40.4-9.el9.x86_64:

$ /home/dodji/git/libabigail/fixes/build/tools/abidiff --d1 evolution-3.40.4-6.el9.x86_64/usr/lib/debug  --d2 evolution-3.40.4-9.el9.x86_64/usr/lib/debug evolution-3.40.4-6.el9.x86_64/usr/lib64/evolution/libevolution-mail.so evolution-3.40.4-9.el9.x86_64/usr/lib64/evolution/libevolution-mail.so  && echo "exit code: $?"
Functions changes summary: 0 Removed, 1 Changed (25 filtered out), 0 Added functions
Variables changes summary: 0 Removed, 0 Changed, 0 Added variable

1 function with some indirect sub-type change:

  [C] 'function GtkAction* e_mail_display_get_action(EMailDisplay*, const gchar*)' at e-mail-display.c:2914:1 has some indirect sub-type changes:
    parameter 1 of type 'EMailDisplay*' has sub-type changes:
      in pointed to type 'typedef EMailDisplay' at e-mail-display.h:50:1:
        underlying type 'struct _EMailDisplay' at e-mail-display.h:54:1 changed:
          type size hasn't changed
          1 data member change:
            type of 'EMailDisplayPrivate* priv' changed:
              in pointed to type 'typedef EMailDisplayPrivate' at e-mail-display.h:52:1:
                underlying type 'struct _EMailDisplayPrivate' at e-mail-display.c:65:1 changed:
                  type size hasn't changed
                  1 data member insertion:
                    'guint iframes_height_update_id', at offset 864 (in bits) at e-mail-display.c:86:1


As abidiff looks into the binary directly, you can see that EmailDisplayPrivate is indeed accessible from the e_mail_display_get_action function, which is an ABI entry point as its ELF symbol is defined and publicly exported from the binary.

From a programmer point of view however, because the struct _EMailDisplay is opaque (just declared in the public header file e-mail-display.h and not defined in any public header file), the currently accepted idiom among developers is to consider "struct _EmailDisplay" as being "private".  As such, any change to the data members of that struct _EMailDisplay is considered harmless, from an ABI point of view.

To apply that idiom, abidiff needs to be made aware of the header files of the package by using the options --hd1 and --hd1 (or their longer --headers-dir1 --headers-dir2 equivalent).

Once I have unpacked the evolution-devel-3.40.4-6.el9.x86_64.rpm and evolution-devel-3.40.4-9.el9.x86_64.rpm into the directories evolution-3.40.4-6.el9.x86_64 and evolution-3.40.4-9.el9.x86_64 respectively, here is what I get when I invoke abidiff with the appropriate --hd1 and --hd2 options:

$ /home/dodji/git/libabigail/fixes/build/tools/abidiff --d1 evolution-3.40.4-6.el9.x86_64/usr/lib/debug --hd1 evolution-3.40.4-6.el9.x86_64/usr/include --d2 evolution-3.40.4-9.el9.x86_64/usr/lib/debug --hd2 evolution-3.40.4-9.el9.x86_64/usr/include evolution-3.40.4-6.el9.x86_64/usr/lib64/evolution/libevolution-mail.so evolution-3.40.4-9.el9.x86_64/usr/lib64/evolution/libevolution-mail.so  && echo "exit code: $?"
Functions changes summary: 0 Removed, 0 Changed (26 filtered out), 0 Added functions
Variables changes summary: 0 Removed, 0 Changed, 0 Added variable

exit code: 0
$

abidiff filters out the the changes to the (now recognized as) private EmailDisplayPrivate data type.

@dcantrell, is there a way to tell rpminspect to include the content of the associated -devel package in the working directory and pass the proper --headers-dir1 and --headers-dir2 option to abidiff to make it take into account private data structures?

Comment 2 David Cantrell 2023-01-26 15:45:02 UTC
(In reply to Dodji Seketeli from comment #1)
> @dcantrell, is there a way to tell rpminspect to include the content of the
> associated -devel package in the working directory and pass the proper
> --headers-dir1 and --headers-dir2 option to abidiff to make it take into
> account private data structures?

I have made this change in rpminspect.  It will pass --hd1 and --hd2 options to abidiff.  I tried it out with this evolution example and it passes.

The PR is here:
https://github.com/rpminspect/rpminspect/pull/1048

Once this is merged, it will be in the next Copr build (which is automatic on merges to the repo).  The next versioned release is 1.11 and this fix will be included there.

Comment 3 RHEL Program Management 2023-09-22 15:55:36 UTC
Issue migration from Bugzilla to Jira is in process at this time. This will be the last message in Jira copied from the Bugzilla bug.

Comment 4 RHEL Program Management 2023-09-22 15:56:29 UTC
This BZ has been automatically migrated to the issues.redhat.com Red Hat Issue Tracker. All future work related to this report will be managed there.

Due to differences in account names between systems, some fields were not replicated.  Be sure to add yourself to Jira issue's "Watchers" field to continue receiving updates and add others to the "Need Info From" field to continue requesting information.

To find the migrated issue, look in the "Links" section for a direct link to the new issue location. The issue key will have an icon of 2 footprints next to it, and begin with "RHEL-" followed by an integer.  You can also find this issue by visiting https://issues.redhat.com/issues/?jql= and searching the "Bugzilla Bug" field for this BZ's number, e.g. a search like:

"Bugzilla Bug" = 1234567

In the event you have trouble locating or viewing this issue, you can file an issue by sending mail to rh-issues. You can also visit https://access.redhat.com/articles/7032570 for general account information.


Note You need to log in before you can comment on or make changes to this bug.