Bug 1465510

Summary: gcc and gcc-libraries debuginfo clash on aarch64
Product: Red Hat Enterprise Linux 7 Reporter: Marek Polacek <mpolacek>
Component: gccAssignee: Marek Polacek <mpolacek>
Status: CLOSED ERRATA QA Contact: Michael Petlan <mpetlan>
Severity: unspecified Docs Contact: Vladimír Slávik <vslavik>
Priority: unspecified    
Version: 7.4CC: jakub, mcermak, mpolacek, ohudlick, vslavik
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: gcc-4.8.5-20.el7 Doc Type: No Doc Update
Doc Text:
Debuginfo conflict with *libatomic* files on 64-bit ARM architecture between _gcc_ and _gcc-libraries_ resolved Previously, on the 64-bit ARM architecture the *libatomic* library was included in the _gcc-libraries_ package but *libatomic* was built also during creation of the _gcc_ package. As a consequence, debuginfo packages for both of the mentioned packages contained files for *libatomic* and conflicted. The conflict has been resolved. As a result, debuginfo packages for _gcc_ and _gcc-debuginfo_ no longer cause a conflict.
Story Points: ---
Clone Of:
: 1474717 (view as bug list) Environment:
Last Closed: 2018-04-10 15:09:27 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1473718, 1474717    

Description Marek Polacek 2017-06-27 14:32:09 UTC
Currently, gcc-4.8.5-16.el7 for aarch64 doesn't ship libatomic, so
gcc-libraries on aarch64 comes with libatomic, to support DTS-built
applications.

Upstream 4.8 doesn't support libatomic on aarch64: in libatomic/configure.tgt
you'll find

case "${target}" in
  aarch64*)
        # This is currently not supported in AArch64.
        UNSUPPORTED=1
        ;;

But redhat/gcc-4.8 actually supports libatomic on aarch64; the bits above were removed in
<https://gcc.gnu.org/viewcvs/gcc/branches/redhat/gcc-4_8-branch/libatomic/configure.tgt?r1=195337&r2=212553>.

But the spec file for rhel7 gcc has:

%ifarch %{ix86} x86_64 ppc ppc64 ppc64le ppc64p7 s390 s390x %{arm}
%global build_libatomic 1
%else
%global build_libatomic 0

%if %{build_libatomic}
%files -n libatomic
[...]

which means that we *build* libatomic on aarch64, it just isn't included in
a subpackage.  But it still ends up in the debuginfo!  So gcc-debuginfo and
gcc-libraries-debuginfo clash.

I believe we should:
 * fix rhel7 gcc spec file so it actually includes the libatomic subpackage on aarch64,
 * drop the libatomic subpackage from gcc-libraries.

Comment 7 Michael Petlan 2018-01-10 11:03:22 UTC
So the debuginfos don't clash anymore:

# rpmquery -a | grep gcc | grep debuginfo
gcc-debuginfo-4.8.5-26.el7.aarch64
gcc-base-debuginfo-4.8.5-26.el7.aarch64
gcc-libraries-debuginfo-7.2.1-1.1.1.el7.aarch64

I don't know what exactly changed, but libatomic remains a part of gcc-libraries, its debuginfo is in gcc-libraries-debuginfo, gcc-debuginfo no more contains conflicting files. So it makes sense and works for me.

VERIFIED.

Comment 8 Marek Polacek 2018-01-10 11:07:08 UTC
(In reply to Michael Petlan from comment #7)
> So the debuginfos don't clash anymore:
> 
> # rpmquery -a | grep gcc | grep debuginfo
> gcc-debuginfo-4.8.5-26.el7.aarch64
> gcc-base-debuginfo-4.8.5-26.el7.aarch64
> gcc-libraries-debuginfo-7.2.1-1.1.1.el7.aarch64
> 
> I don't know what exactly changed, but libatomic remains a part of
> gcc-libraries, its debuginfo is in gcc-libraries-debuginfo, gcc-debuginfo no
> more contains conflicting files. So it makes sense and works for me.

Correct, the change was in the end in gcc, so this is expected.

Comment 11 errata-xmlrpc 2018-04-10 15:09:27 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2018:0849