From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 7038 invoked by alias); 16 Jun 2014 14:11:20 -0000 Mailing-List: contact binutils-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: binutils-owner@sourceware.org Received: (qmail 7028 invoked by uid 89); 16 Jun 2014 14:11:20 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.0 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 X-HELO: mail-ie0-f177.google.com Received: from mail-ie0-f177.google.com (HELO mail-ie0-f177.google.com) (209.85.223.177) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-SHA encrypted) ESMTPS; Mon, 16 Jun 2014 14:11:14 +0000 Received: by mail-ie0-f177.google.com with SMTP id tp5so4815832ieb.8 for ; Mon, 16 Jun 2014 07:11:12 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:content-type; bh=lli7hOJTMxOVNj9rJoQIhuNzDcXrrwbDMgb//lF9/gE=; b=Z4EAfIn16wWuHwKguiY+pckRTJbjiXMaSkhly5iOL04wOSE5oozl7u41wjd3+4b/7X y+whmPqpnVy4RTgzHEu/6fwDqt/7m+uUgwGsWxMRHCRsDif8S295bE1jy3gQ6w8DrTCK VnnFz7sbUgqN9/X253jrjtmLvuTQaFDwHVlUvCMi0c5F8RMrf6q9ysMpBwewhaDzCcc0 MogcII9VolGrjwBDPkbm5cf77qj5RCkJQNzQAvC3CiFPjKS3W5+7Mz5x8vOjZaID495m Oe79xT/z6+ChxokNOk+NbdwOh8XJ4L4yl7snjxJmi87RpouIAp5RsxuPoHrZ7VI4Dfnu DBhw== X-Gm-Message-State: ALoCoQnj/JapmtSlLZJZcLKPE78j5UpOH/kmSXoAeG2U+lbUM1aQSP5m3n2Raw2A6dPyL5YoqXPa MIME-Version: 1.0 X-Received: by 10.43.137.74 with SMTP id in10mr21676831icc.54.1402927872542; Mon, 16 Jun 2014 07:11:12 -0700 (PDT) Received: by 10.64.225.50 with HTTP; Mon, 16 Jun 2014 07:11:12 -0700 (PDT) In-Reply-To: References: <53918356.3040102@embedded-brains.de> <20140606105420.GH5592@bubble.grove.modra.org> <5391A4BF.2030308@embedded-brains.de> <20140606121659.GJ5592@bubble.grove.modra.org> <20140607124711.GO5592@bubble.grove.modra.org> <20140616130719.GK3462@bubble.grove.modra.org> Date: Mon, 16 Jun 2014 14:11:00 -0000 Message-ID: Subject: Re: 32-bit PowerPC sdata linker problem From: Will Newton To: Will Newton , "binutils@sourceware.org" Content-Type: text/plain; charset=UTF-8 X-IsSubscribed: yes X-SW-Source: 2014-06/txt/msg00138.txt.bz2 On 16 June 2014 15:09, Will Newton wrote: > On 16 June 2014 14:07, Alan Modra wrote: >> On Mon, Jun 16, 2014 at 12:21:23PM +0100, Will Newton wrote: >>> PROVIDE_HIDDEN (__rel_iplt_start = .); >>> *(.rel.iplt) >>> PROVIDE_HIDDEN (__rel_iplt_end = .); >>> PROVIDE_HIDDEN (__rela_iplt_start = .); >>> PROVIDE_HIDDEN (__rela_iplt_end = .); >> >> This should fix it. Committed. >> >> * scripttempl/elf.sc: Edit out __rela_iplt symbol assignments from >> .rel sections, and __rel_iplt from .rela sections. >> * scripttempl/nds32elf.sc: Likewise. >> * Makefile.am (ends32*.c) Depend on nds32elf.sc. >> * Makefile.in: Regenerate. > > Yes, this fixes the problem for me. Thanks! Would it be possible to apply the fix to the stable branch too? >> diff --git a/ld/Makefile.am b/ld/Makefile.am >> index 66795b3..a22006c 100644 >> --- a/ld/Makefile.am >> +++ b/ld/Makefile.am >> @@ -1490,27 +1490,27 @@ emsp430X.c: $(srcdir)/emulparams/msp430.sh $(srcdir)/emulparams/msp430X.sh \ >> >> ends32elf.c: $(srcdir)/emulparams/nds32elf.sh \ >> $(ELF_DEPS) $(srcdir)/emultempl/nds32elf.em \ >> - $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS} >> + $(srcdir)/scripttempl/nds32elf.sc ${GEN_DEPENDS} >> >> ends32elf16m.c: $(srcdir)/emulparams/nds32elf16m.sh \ >> $(ELF_DEPS) $(srcdir)/emultempl/nds32elf.em \ >> - $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS} >> + $(srcdir)/scripttempl/nds32elf.sc ${GEN_DEPENDS} >> >> ends32belf.c: $(srcdir)/emulparams/nds32belf.sh \ >> $(ELF_DEPS) $(srcdir)/emultempl/nds32elf.em \ >> - $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS} >> + $(srcdir)/scripttempl/nds32elf.sc ${GEN_DEPENDS} >> >> ends32belf16m.c: $(srcdir)/emulparams/nds32belf16m.sh \ >> $(ELF_DEPS) $(srcdir)/emultempl/nds32elf.em \ >> - $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS} >> + $(srcdir)/scripttempl/nds32elf.sc ${GEN_DEPENDS} >> >> ends32elf_linux.c: $(srcdir)/emulparams/nds32elf_linux.sh \ >> $(ELF_DEPS) $(srcdir)/emultempl/nds32elf.em \ >> - $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS} >> + $(srcdir)/scripttempl/nds32elf.sc ${GEN_DEPENDS} >> >> ends32belf_linux.c: $(srcdir)/emulparams/nds32belf_linux.sh \ >> $(ELF_DEPS) $(srcdir)/emultempl/nds32elf.em \ >> - $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS} >> + $(srcdir)/scripttempl/nds32elf.sc ${GEN_DEPENDS} >> >> enews.c: $(srcdir)/emulparams/news.sh \ >> $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/aout.sc ${GEN_DEPENDS} >> diff --git a/ld/scripttempl/elf.sc b/ld/scripttempl/elf.sc >> index e8126cb..6d0d13d 100644 >> --- a/ld/scripttempl/elf.sc >> +++ b/ld/scripttempl/elf.sc >> @@ -410,13 +410,13 @@ cat >> ldscripts/dyntmp.$$ <> .rel.dyn ${RELOCATING-0} : >> { >> EOF >> -sed -e '/^[ ]*[{}][ ]*$/d;/:[ ]*$/d;/\.rela\./d;s/^.*: { *\(.*\)}$/ \1/' $COMBRELOC >> ldscripts/dyntmp.$$ >> +sed -e '/^[ ]*[{}][ ]*$/d;/:[ ]*$/d;/\.rela\./d;/__rela_iplt_/d;s/^.*: { *\(.*\)}$/ \1/' $COMBRELOC >> ldscripts/dyntmp.$$ >> cat >> ldscripts/dyntmp.$$ <> } >> .rela.dyn ${RELOCATING-0} : >> { >> EOF >> -sed -e '/^[ ]*[{}][ ]*$/d;/:[ ]*$/d;/\.rel\./d;s/^.*: { *\(.*\)}/ \1/' $COMBRELOC >> ldscripts/dyntmp.$$ >> +sed -e '/^[ ]*[{}][ ]*$/d;/:[ ]*$/d;/\.rel\./d;/__rel_iplt_/d;s/^.*: { *\(.*\)}/ \1/' $COMBRELOC >> ldscripts/dyntmp.$$ >> cat >> ldscripts/dyntmp.$$ <> } >> EOF >> @@ -446,10 +446,10 @@ emit_dyn() >> cat ldscripts/dyntmp.$$ >> else >> if test -z "${NO_REL_RELOCS}"; then >> - sed -e '/^[ ]*\.rela\.[^}]*$/,/}/d' -e '/^[ ]*\.rela\./d' ldscripts/dyntmp.$$ >> + sed -e '/^[ ]*\.rela\.[^}]*$/,/}/d;/^[ ]*\.rela\./d;/__rela_iplt_/d' ldscripts/dyntmp.$$ >> fi >> if test -z "${NO_RELA_RELOCS}"; then >> - sed -e '/^[ ]*\.rel\.[^}]*$/,/}/d' -e '/^[ ]*\.rel\./d' ldscripts/dyntmp.$$ >> + sed -e '/^[ ]*\.rel\.[^}]*$/,/}/d;/^[ ]*\.rel\./d;/__rel_iplt_/d' ldscripts/dyntmp.$$ >> fi >> fi >> rm -f ldscripts/dyntmp.$$ >> diff --git a/ld/scripttempl/nds32elf.sc b/ld/scripttempl/nds32elf.sc >> index 80f60a1..076e120 100644 >> --- a/ld/scripttempl/nds32elf.sc >> +++ b/ld/scripttempl/nds32elf.sc >> @@ -361,13 +361,13 @@ cat >> ldscripts/dyntmp.$$ <> .rel.dyn ${RELOCATING-0} : >> { >> EOF >> -sed -e '/^[ ]*[{}][ ]*$/d;/:[ ]*$/d;/\.rela\./d;s/^.*: { *\(.*\)}$/ \1/' $COMBRELOC >> ldscripts/dyntmp.$$ >> +sed -e '/^[ ]*[{}][ ]*$/d;/:[ ]*$/d;/\.rela\./d;/__rela_iplt_/d;s/^.*: { *\(.*\)}$/ \1/' $COMBRELOC >> ldscripts/dyntmp.$$ >> cat >> ldscripts/dyntmp.$$ <> } >> .rela.dyn ${RELOCATING-0} : >> { >> EOF >> -sed -e '/^[ ]*[{}][ ]*$/d;/:[ ]*$/d;/\.rel\./d;s/^.*: { *\(.*\)}/ \1/' $COMBRELOC >> ldscripts/dyntmp.$$ >> +sed -e '/^[ ]*[{}][ ]*$/d;/:[ ]*$/d;/\.rel\./d;/__rel_iplt_/d;s/^.*: { *\(.*\)}/ \1/' $COMBRELOC >> ldscripts/dyntmp.$$ >> cat >> ldscripts/dyntmp.$$ <> } >> EOF >> @@ -397,10 +397,10 @@ emit_dyn() >> cat ldscripts/dyntmp.$$ >> else >> if test -z "${NO_REL_RELOCS}"; then >> - sed -e '/^[ ]*\.rela\.[^}]*$/,/}/d' -e '/^[ ]*\.rela\./d' ldscripts/dyntmp.$$ >> + sed -e '/^[ ]*\.rela\.[^}]*$/,/}/d;/^[ ]*\.rela\./d;/__rela_iplt_/d' ldscripts/dyntmp.$$ >> fi >> if test -z "${NO_RELA_RELOCS}"; then >> - sed -e '/^[ ]*\.rel\.[^}]*$/,/}/d' -e '/^[ ]*\.rel\./d' ldscripts/dyntmp.$$ >> + sed -e '/^[ ]*\.rel\.[^}]*$/,/}/d;/^[ ]*\.rel\./d;/__rel_iplt_/d' ldscripts/dyntmp.$$ >> fi >> fi >> rm -f ldscripts/dyntmp.$$ >> >> -- >> Alan Modra >> Australia Development Lab, IBM > > > > -- > Will Newton > Toolchain Working Group, Linaro -- Will Newton Toolchain Working Group, Linaro