[OE-core] [PATCH] matchbox-keyboard: Fix build failure with ld-is-gold

Khem Raj raj.khem at gmail.com
Thu Jan 14 18:27:21 UTC 2016


Carlos

Can you try this fix

https://github.com/kraj/openembedded-core/commit/0e35ad5a35262cfb7a6249ce158f76d1399d6cb4


This should help with this issue.


> On Sep 14, 2015, at 4:01 PM, Carlos Alberto Lopez Perez <clopez at igalia.com> wrote:
> 
> On 14/09/15 09:24, Khem Raj wrote:
>> 
>>> On Sep 11, 2015, at 7:51 AM, Phil Blundell <pb at pbcl.net> wrote:
>>> 
>>> On Fri, 2015-09-11 at 14:49 +0200, Carlos Alberto Lopez Perez wrote:
>>>> * When ld-is-gold is enabled in DISTRO_FEATURES, matchbox-keyboard
>>>>   will fail to build with this error:
>>>> 
>>>>   ld: error: matchbox-keyboard-image.o: requires unsupported dynamic
>>>>              reloc R_ARM_MOVW_ABS_NC; recompile with -fPIC
>>> 
>>> This is only an issue for ARM (and only for Thumb2 at that).  I don't
>>> think it's necessarily appropriate to force -fPIC on all targets.
>>> 
>>> Also, before adding this sort of hack it would be worth verifying
>>> whether this is in fact a toolchain bug and, if it is, fixing it there.
>>> 
>> 
>> This may not be a toolchain bug if there is a MOVW_ABS relocation being emitted
>> into an object that is eventually linked into shared library. Using -fPIC seems to be right fix
>> I know bfd linker silently ignored these relocations and generated bad .so files but that was fixed
>> several years ago. So I think what needs to be looked at is why does same .o links ok with bfd linker
>> is it some linker trampoline code thats in question here which may be different between gold and ld
>> 
>> Carlos
>> 
>> Can you check the linker cmdline of failing link step and see if its generating a shared object there ?
>> if thats the case and I assume gcc is generating this relocation into both
>> 
> 
> It looks is generating an executable (matchbox-keyboard).
> 
> Full log: http://sprunge.us/VPIN
> 

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 204 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://lists.openembedded.org/pipermail/openembedded-core/attachments/20160114/a0df4090/attachment-0002.sig>


More information about the Openembedded-core mailing list