This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: arm-wince-pe's objects are incompatible with WinCE linker
- From: Dmitry Semyonov <Dmitry dot Semyonov at oktet dot ru>
- To: <binutils at sources dot redhat dot com>
- Cc: <crossgcc at sources dot redhat dot com>
- Date: Wed, 12 Nov 2003 21:42:46 +0300 (MSK)
- Subject: Re: arm-wince-pe's objects are incompatible with WinCE linker
- Reply-to: <Dmitry dot Semyonov at oktet dot ru>
On Tue, 11 Nov 2003, Dmitry Semyonov wrote:
> I'm trying to create an object file from a C source with the following
> function:
[...]
> (arm-wince-pe-gcc -fno-leading-underscore -S str_test.c) produces
> the following asm output:
[...]
> Microsoft linker from WinCE 4.2 expects both L2 and L2+4 words to be
> zeros in object file. (Actual addresses of LC0 and LC1 strings are
> _added_ to L2 and L2+4 words during linking). But L2+4 word contains
> value of 8 (offset of LC1 string) instead.
>
> Is there an option to control the behavior of gas in the way MS linker
> expects?
>
> If not then it is a bug in gas or bfd. I'm currently trying to determine
> the exact place. Any help would be welcome, since I'm not very familiar
> with binutils.
Well, the bug was found. Thanks Victor Vengerov from Oktet for helping
with determining the right place for a fix.
It is in bfd/coff-arm.c: partial_inplace field(s?) of static
aoutarm_std_reloc_howto structure is(are?) defined so that resulting
object files are incompatible with MS linker.
I want to peform more testing to be sure our changes are not breaking
some functionality. Then I'll submit a patch.
...Bye..Dmitry.