Bug 22322 - [mips64] wrong bits/long-double.h installed
Summary: [mips64] wrong bits/long-double.h installed
Status: RESOLVED FIXED
Alias: None
Product: glibc
Classification: Unclassified
Component: libc (show other bugs)
Version: 2.26
: P2 normal
Target Milestone: 2.27
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-10-19 17:04 UTC by Joseph Myers
Modified: 2017-10-23 15:50 UTC (History)
1 user (show)

See Also:
Host: mips*-*-*
Target:
Build:
Last reconfirmed:
fweimer: security-


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Joseph Myers 2017-10-19 17:04:47 UTC
Similar to bug 21987 for SPARC, MIPS64 wrongly installs the ldbl-128 version of bits/long-double.h, meaning incorrect results when using headers installed from a 64-bit installation for a 32-bit build.  (I haven't actually seen this cause build failures before its interaction with bits/floatn.h did so.)
Comment 1 Sourceware Commits 2017-10-19 17:33:15 UTC
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".

The branch, master has been updated
       via  37bb78cb8c1fb6b5813407c8856b1557359e6343 (commit)
      from  d74e6f6c0de55fc588b1ac09c88eb0fb8b8600af (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=37bb78cb8c1fb6b5813407c8856b1557359e6343

commit 37bb78cb8c1fb6b5813407c8856b1557359e6343
Author: Joseph Myers <joseph@codesourcery.com>
Date:   Thu Oct 19 17:32:20 2017 +0000

    Install correct bits/long-double.h for MIPS64 (bug 22322).
    
    Similar to bug 21987 for SPARC, MIPS64 wrongly installs the ldbl-128
    version of bits/long-double.h, meaning incorrect results when using
    headers installed from a 64-bit installation for a 32-bit build.  (I
    haven't actually seen this cause build failures before its interaction
    with bits/floatn.h did so - installed headers wrongly expecting
    _Float128 to be available in a 32-bit configuration.)
    
    This patch fixes the bug by moving the MIPS header to
    sysdeps/mips/ieee754, which comes before sysdeps/ieee754/ldbl-128 in
    the sysdeps directory ordering.  (bits/floatn.h will need a similar
    fix - duplicating the ldbl-128 version for MIPS will suffice - for
    headers from a 32-bit installation to be correct for 64-bit builds.)
    
    Tested with build-many-glibcs.py (compilers build for
    mips64-linux-gnu, where there was previously a libstdc++ build failure
    as at
    <https://sourceware.org/ml/libc-testresults/2017-q4/msg00130.html>).
    
    	[BZ #22322]
    	* sysdeps/mips/bits/long-double.h: Move to ....
    	* sysdeps/mips/ieee754/bits/long-double.h: ... here.

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog                                     |    6 ++++++
 sysdeps/mips/{ => ieee754}/bits/long-double.h |    0
 2 files changed, 6 insertions(+), 0 deletions(-)
 rename sysdeps/mips/{ => ieee754}/bits/long-double.h (100%)
Comment 2 Joseph Myers 2017-10-19 17:36:30 UTC
Fixed for 2.27.
Comment 3 Sourceware Commits 2017-10-23 15:47:40 UTC
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".

The branch, release/2.26/master has been updated
       via  04acd597943e90147e4bc139911564788e04ae51 (commit)
      from  b1b8d8aa95a055dc7929259679a995189d444809 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=04acd597943e90147e4bc139911564788e04ae51

commit 04acd597943e90147e4bc139911564788e04ae51
Author: Joseph Myers <joseph@codesourcery.com>
Date:   Thu Oct 19 17:32:20 2017 +0000

    Install correct bits/long-double.h for MIPS64 (bug 22322).
    
    Similar to bug 21987 for SPARC, MIPS64 wrongly installs the ldbl-128
    version of bits/long-double.h, meaning incorrect results when using
    headers installed from a 64-bit installation for a 32-bit build.  (I
    haven't actually seen this cause build failures before its interaction
    with bits/floatn.h did so - installed headers wrongly expecting
    _Float128 to be available in a 32-bit configuration.)
    
    This patch fixes the bug by moving the MIPS header to
    sysdeps/mips/ieee754, which comes before sysdeps/ieee754/ldbl-128 in
    the sysdeps directory ordering.  (bits/floatn.h will need a similar
    fix - duplicating the ldbl-128 version for MIPS will suffice - for
    headers from a 32-bit installation to be correct for 64-bit builds.)
    
    Tested with build-many-glibcs.py (compilers build for
    mips64-linux-gnu, where there was previously a libstdc++ build failure
    as at
    <https://sourceware.org/ml/libc-testresults/2017-q4/msg00130.html>).
    
    	[BZ #22322]
    	* sysdeps/mips/bits/long-double.h: Move to ....
    	* sysdeps/mips/ieee754/bits/long-double.h: ... here.
    
    (cherry picked from commit 37bb78cb8c1fb6b5813407c8856b1557359e6343)

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog                                     |    6 ++++++
 NEWS                                          |    1 +
 sysdeps/mips/{ => ieee754}/bits/long-double.h |    0
 3 files changed, 7 insertions(+), 0 deletions(-)
 rename sysdeps/mips/{ => ieee754}/bits/long-double.h (100%)
Comment 4 Sourceware Commits 2017-10-23 15:50:04 UTC
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".

The branch, release/2.25/master has been updated
       via  0fc015b6db6a1591d2beecb98362f5de175a077f (commit)
      from  61bebc863e65afd994b08353f574c5df3fe8accc (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=0fc015b6db6a1591d2beecb98362f5de175a077f

commit 0fc015b6db6a1591d2beecb98362f5de175a077f
Author: Joseph Myers <joseph@codesourcery.com>
Date:   Thu Oct 19 17:32:20 2017 +0000

    Install correct bits/long-double.h for MIPS64 (bug 22322).
    
    Similar to bug 21987 for SPARC, MIPS64 wrongly installs the ldbl-128
    version of bits/long-double.h, meaning incorrect results when using
    headers installed from a 64-bit installation for a 32-bit build.  (I
    haven't actually seen this cause build failures before its interaction
    with bits/floatn.h did so - installed headers wrongly expecting
    _Float128 to be available in a 32-bit configuration.)
    
    This patch fixes the bug by moving the MIPS header to
    sysdeps/mips/ieee754, which comes before sysdeps/ieee754/ldbl-128 in
    the sysdeps directory ordering.  (bits/floatn.h will need a similar
    fix - duplicating the ldbl-128 version for MIPS will suffice - for
    headers from a 32-bit installation to be correct for 64-bit builds.)
    
    Tested with build-many-glibcs.py (compilers build for
    mips64-linux-gnu, where there was previously a libstdc++ build failure
    as at
    <https://sourceware.org/ml/libc-testresults/2017-q4/msg00130.html>).
    
    	[BZ #22322]
    	* sysdeps/mips/bits/long-double.h: Move to ....
    	* sysdeps/mips/ieee754/bits/long-double.h: ... here.
    
    (cherry picked from commit 37bb78cb8c1fb6b5813407c8856b1557359e6343)

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog                                     |    6 ++++++
 NEWS                                          |    1 +
 sysdeps/mips/{ => ieee754}/bits/long-double.h |    0
 3 files changed, 7 insertions(+), 0 deletions(-)
 rename sysdeps/mips/{ => ieee754}/bits/long-double.h (100%)