public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jeff Law <law@redhat.com>
To: gcc-patches List <gcc-patches@gcc.gnu.org>
Subject: Fix libgcc build failure on FRV
Date: Mon, 10 Feb 2020 21:14:00 -0000	[thread overview]
Message-ID: <c569b0c00067b73cf67270d2746c2672c176eb0f.camel@redhat.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 478 bytes --]

Alan recently changed the diagnostic in binutils for changing various
attributes of a section from a warning to a hard error.


This caused the FRV port to fail to build frvbegin/frvend because of
differences in the flags for the .ctors/.dtors sections.

This patch twiddles frvbegin.c/frvend.c in libgcc to avoid the error.

I've verified this fixes the libgcc build failure for FRV and verified
that the GCC testresults have returned to normal.

Installed on the trunk,

Jeff

[-- Attachment #2: P --]
[-- Type: text/plain, Size: 2068 bytes --]

commit 7214fce3024d726ad548d7003fa162eb5021c491
Author: Jeff Law <law@redhat.com>
Date:   Mon Feb 10 14:12:32 2020 -0700

    Fix libgcc build failure for FRV with recent versions of gas.
    
            * config/frv/frvbegin.c: Use right flags for .ctors and .dtors
            sections.
            * config/frv/frvend.c: Similarly.

diff --git a/libgcc/ChangeLog b/libgcc/ChangeLog
index 4c7443a0457..917d0e76568 100644
--- a/libgcc/ChangeLog
+++ b/libgcc/ChangeLog
@@ -1,3 +1,9 @@
+2020-02-10  Jeff Law  <law@redhat.com>
+
+	* config/frv/frvbegin.c: Use right flags for .ctors and .dtors
+	sections.
+	* config/frv/frvend.c: Similarly.
+
 2020-02-10  H.J. Lu  <hongjiu.lu@intel.com>
 
 	PR libgcc/85334
diff --git a/libgcc/config/frv/frvbegin.c b/libgcc/config/frv/frvbegin.c
index 8ab1a1b989d..0f54bf19646 100644
--- a/libgcc/config/frv/frvbegin.c
+++ b/libgcc/config/frv/frvbegin.c
@@ -59,8 +59,8 @@ __asm__ (".section " SECTION "," FLAGS "\n\t"				\
 /* Beginning of .ctor/.dtor sections that provides a list of constructors and
    destructors to run.  */
 
-INIT_SECTION_NEG_ONE (".ctors", "\"aw\"", "__CTOR_LIST__");
-INIT_SECTION_NEG_ONE (".dtors", "\"aw\"", "__DTOR_LIST__");
+INIT_SECTION_NEG_ONE (".ctors", "\"a\"", "__CTOR_LIST__");
+INIT_SECTION_NEG_ONE (".dtors", "\"a\"", "__DTOR_LIST__");
 
 /* Beginning of .eh_frame section that provides all of the exception handling
    tables.  */
diff --git a/libgcc/config/frv/frvend.c b/libgcc/config/frv/frvend.c
index eb3494cad96..d2b83b294ca 100644
--- a/libgcc/config/frv/frvend.c
+++ b/libgcc/config/frv/frvend.c
@@ -52,8 +52,8 @@ __asm__ (".section " SECTION "," FLAGS "\n\t"				\
 /* End of .ctor/.dtor sections that provides a list of constructors and
    destructors to run.  */
 
-FINI_SECTION_ZERO (".ctors", "\"aw\"", "__CTOR_END__");
-FINI_SECTION_ZERO (".dtors", "\"aw\"", "__DTOR_END__");
+FINI_SECTION_ZERO (".ctors", "\"a\"", "__CTOR_END__");
+FINI_SECTION_ZERO (".dtors", "\"a\"", "__DTOR_END__");
 
 /* End of .eh_frame section that provides all of the exception handling
    tables.  */

                 reply	other threads:[~2020-02-10 21:14 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=c569b0c00067b73cf67270d2746c2672c176eb0f.camel@redhat.com \
    --to=law@redhat.com \
    --cc=gcc-patches@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).