From patchwork Mon Oct 8 20:04:51 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Peter Korsgaard X-Patchwork-Id: 190117 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from fraxinus.osuosl.org (fraxinus.osuosl.org [140.211.166.137]) by ozlabs.org (Postfix) with ESMTP id 31D9B2C031A for ; Tue, 9 Oct 2012 07:06:58 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id CEE6C10205A; Mon, 8 Oct 2012 20:06:52 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id aItlLFRaVWbf; Mon, 8 Oct 2012 20:06:48 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by fraxinus.osuosl.org (Postfix) with ESMTP id 94493101DEB; Mon, 8 Oct 2012 20:05:27 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from whitealder.osuosl.org (whitealder.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id B96628F74A for ; Mon, 8 Oct 2012 20:05:31 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 2341C8B7CA for ; Mon, 8 Oct 2012 20:05:29 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 8bBHAT4DfXix for ; Mon, 8 Oct 2012 20:05:24 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-wg0-f53.google.com (mail-wg0-f53.google.com [74.125.82.53]) by whitealder.osuosl.org (Postfix) with ESMTPS id 3E5CD8BBCE for ; Mon, 8 Oct 2012 20:04:57 +0000 (UTC) Received: by mail-wg0-f53.google.com with SMTP id dr1so2965339wgb.10 for ; Mon, 08 Oct 2012 13:04:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-type:content-transfer-encoding; bh=08yq4zMhJWiqtCdOGWsVFEU2JCijUKDec1SHKLaPwos=; b=hHFqryC5Y7/j8I6RdgrX3rAkJ6bM8TlVt0LWy/PrTjr4NY8Dm6WkJnkm12HZWuy07N Il9JE0k9xp5a6qqv5AnVuyR7ghaxujXhUOWiqfByYl6ZWkDEpDQRU+7mb6s+7HEehhfh zJfURBdjk1V3iPxSDOimV2vU9BQqffSLcIrK0jtapjh8RwCoBPU1KGdx68n4BI5+JqBh sqvZGknop+u4E68cAt/hE9Hdwph4wGmyKHpOgdvDuwAB5H5YyIOch9ZjiHbvVPTlztEx GV/u/0ckPNbYuAQCoBCx+fCqf5k3SwH5QkWYoOj4wALp5bf8H/yZ49bf3r4UHUWP4Uu3 KZLQ== Received: by 10.180.73.76 with SMTP id j12mr24354801wiv.11.1349726695471; Mon, 08 Oct 2012 13:04:55 -0700 (PDT) Received: from macbook.be.48ers.dk ([2001:6f8:1434:0:21b:63ff:fec4:4708]) by mx.google.com with ESMTPS id cl8sm21300131wib.10.2012.10.08.13.04.53 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 08 Oct 2012 13:04:54 -0700 (PDT) Received: by macbook.be.48ers.dk (Postfix, from userid 1000) id 0B379C3A82; Mon, 8 Oct 2012 22:04:51 +0200 (CEST) From: Peter Korsgaard To: =?utf-8?Q?Gr=C3=A9gory?= Hermant References: <506A9061.3010300@calao-systems.com> Date: Mon, 08 Oct 2012 22:04:51 +0200 In-Reply-To: <506A9061.3010300@calao-systems.com> (=?utf-8?Q?=22Gr=C3=A9go?= =?utf-8?Q?ry?= Hermant"'s message of "Tue, 02 Oct 2012 08:57:37 +0200") Message-ID: <87txu43f30.fsf@macbook.be.48ers.dk> User-Agent: Gnus/5.110009 (No Gnus v0.9) Emacs/22.3 (gnu/linux) MIME-Version: 1.0 Cc: buildroot@busybox.net Subject: Re: [Buildroot] [PATCH] at91bootstrap: fix gcc-4.6.x overlap linker issue X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.14 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: buildroot-bounces@busybox.net Sender: buildroot-bounces@busybox.net >>>>> "Grégory" == Grégory Hermant writes: Grégory> --- Grégory> ...at91bootstrap-1.16-gcc-4.6.x-ldscript-fix.patch | 53 ++++++++++++++++++++ Grégory> 1 file changed, 53 insertions(+) Grégory> create mode 100644 boot/at91bootstrap/at91bootstrap-1.16-gcc-4.6.x-ldscript-fix.patch Grégory> diff --git a/boot/at91bootstrap/at91bootstrap-1.16-gcc-4.6.x-ldscript-fix.patch b/boot/at91bootstrap/at91bootstrap-1.16-gcc-4.6.x-ldscript-fix.patch Grégory> new file mode 100644 Grégory> index 0000000..56947c7 Grégory> --- /dev/null Grégory> +++ b/boot/at91bootstrap/at91bootstrap-1.16-gcc-4.6.x-ldscript-fix.patch Grégory> @@ -0,0 +1,53 @@ Grégory> +From 5a094e959cd216c1be148effc624eb12e2083de9 Mon Sep 17 00:00:00 2001 Grégory> +From: Gregory Hermant Grégory> +Date: Mon, 1 Oct 2012 16:54:43 +0200 Grégory> +Subject: [PATCH] at91bootstrap-v1.16-ldscript-fix Grégory> + Grégory> +--- Grégory> + crt0_gnu.S | 2 +- Grégory> + elf32-littlearm.lds | 12 +++++++++++- Grégory> + 2 files changed, 12 insertions(+), 2 deletions(-) Grégory> + Grégory> +diff --git a/crt0_gnu.S b/crt0_gnu.S Grégory> +index 002feef..ea6581f 100644 Grégory> +--- a/crt0_gnu.S Grégory> ++++ b/crt0_gnu.S Grégory> +@@ -191,7 +191,7 @@ _go: Grégory> + + .align Grégory> + _lp_data: Grégory> +- .word _etext Grégory> ++ .word _edummy Grégory> + .word _sdata Grégory> + .word _edata Grégory> + +diff --git a/elf32-littlearm.lds b/elf32-littlearm.lds Grégory> +index a33952f..17b1646 100644 Grégory> +--- a/elf32-littlearm.lds Grégory> ++++ b/elf32-littlearm.lds Grégory> +@@ -10,11 +10,21 @@ SECTIONS Grégory> + *(.rodata) /* read-only data (constants) */ Grégory> + *(.rodata*) Grégory> + . = ALIGN(4); Grégory> ++ *(.glue_7) Grégory> ++ . = ALIGN(4); Grégory> ++ *(.eh_frame) Grégory> ++ . = ALIGN(4); Is all of that needed? Isn't it just that gcc 4.6+ adds a bunch of .text. sections? I've fixed it up for an internal tree at work by just doing: diff --git a/elf32-littlearm.lds b/elf32-littlearm.lds index a33952f..f50c30c 100644 --- a/elf32-littlearm.lds +++ b/elf32-littlearm.lds @@ -6,7 +6,7 @@ SECTIONS . = ALIGN(4); .text : { _stext = .; - *(.text) + *(.text*) *(.rodata) /* read-only data (constants) */ *(.rodata*) . = ALIGN(4);