public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Albert ARIBAUD <albert.aribaud@free.fr>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] ARM: fix broken build of ARM
Date: Thu, 27 Jan 2011 22:10:25 +0100	[thread overview]
Message-ID: <4D41DF41.4000708@free.fr> (raw)
In-Reply-To: <4D41DBC7.5090203@ahsoftware.de>

Le 27/01/2011 21:55, Alexander Holler a ?crit :
> Am 27.01.2011 21:20, schrieb Albert ARIBAUD:
>> Hi Alexander,
>>
>> Le 27/01/2011 20:42, Alexander Holler a ?crit :
>>> Hello,
>>>
>>> Am 27.01.2011 17:03, schrieb Stefano Babic:
>>>> Commit 8aba9dceebb14144e07d19593111ee3a999c37fc breaks
>>>> ARM boards because for ARM the -pie option is used
>>>> for partial linking together with -r option.
>>>>
>>>> The patch adds the -pie option to link u-boot.bin only.
>>>
>>> Using native compilation with gcc 4.5.2 and binutils 2.21 this patch
>>> will result in an unusable u-boot. It halts here after DRAM: ... just
>>> like it was before some relocation fixes (regarding binutils).
>>
>> Which board do you compile?
>
> Upps, sorry, that one was on a BeagleBoard (armv7, omap3).

I've just tried the following to compare make logs of before commit 
8aba9dceebb14144e07d19593111ee3a999c37fc on the one hand and after this 
commit and with the proposed fix on the other hand:

git checkout 8aba9dceebb14144e07d19593111ee3a999c37fc^

(that's the commit just before the one which split LD_FLAGS)

make distclean ; make edminiv2_config; make > ~/old.txt 2>&1

git checkout 8aba9dceebb14144e07d19593111ee3a999c37fc

(that's the commit which split LD_FLAGS)

(replace "PLATFORM_LDFLAGS += -pie" with "LDFLAGS_u-boot += -pie" in 
arch/arm/config.mk)

make distclean ; make edminiv2_config; make > ~/new.txt 2>&1

(and finally)

kdiff3 ~/old.txt ~/new.txt

The only difference I see between the make logs is the relative location 
of the -pie option in the final ld invocation: in the 'old' case options go

	...  -Bstatic -T u-boot.lds  -pie -Ttext ...

whereas in the 'new' case, they go

	... -pie -Bstatic -T u-boot.lds  -Ttext ...

So I think the binary should be pretty much the same in the 'old' and 
'new' cases, and that should be irrespective of the tool chain.

Alexander, can you run the same test with your BeagleBoard and let me 
know of any differences?

> Regards,
>
> Alexander

Amicalement,
-- 
Albert.

  reply	other threads:[~2011-01-27 21:10 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-01-27 16:03 [U-Boot] [PATCH] ARM: fix broken build of ARM Stefano Babic
2011-01-27 19:42 ` Alexander Holler
2011-01-27 20:20   ` Albert ARIBAUD
2011-01-27 20:55     ` Alexander Holler
2011-01-27 21:10       ` Albert ARIBAUD [this message]
2011-01-27 21:14         ` Wolfgang Denk
2011-01-27 21:32           ` Albert ARIBAUD
2011-01-27 21:32         ` Alexander Holler
2011-01-27 21:40           ` Albert ARIBAUD
2011-01-27 22:19             ` Alexander Holler
2011-01-27 22:37               ` Albert ARIBAUD
2011-01-27 22:44               ` Stefano Babic
2011-01-27 22:44 ` Alexander Holler
2011-01-27 22:54   ` Albert ARIBAUD

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=4D41DF41.4000708@free.fr \
    --to=albert.aribaud@free.fr \
    --cc=u-boot@lists.denx.de \
    /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