This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
RE: Assembler messages [PATCH]
- From: "Dave Korn" <dk at artimi dot com>
- To: "'Shaun Jackman'" <sjackman at telus dot net>,<binutils at sources dot redhat dot com>
- Cc: "'Richard Earnshaw'" <Richard dot Earnshaw at arm dot com>
- Date: Fri, 11 Jun 2004 18:04:47 +0100
- Subject: RE: Assembler messages [PATCH]
> -----Original Message-----
> From: binutils-owner On Behalf Of Shaun Jackman
> Sent: 11 June 2004 17:21
> Ah! Sorry. I understand your original post to me now. Is it at all
> possible to generate the following form?
>
> [a.s]
> .text
> a:
> .word 0
>
> [b.s]
> .text
> b:
> ldr r0, a
>
> To me, just because the symbol and the referencer are in different
> files shouldn't end the world. That's why we have a linker. If you
> merge the two files it works just fine.
Yes, that'll work fine. In the prior example, the symbol X was assumed
not to actually be defined anywhere else, I assume.
> and a check for the second case is needed:
> "`%s' must be defined in the same section"
When gas detects that two symbols are in different sections and the abi
doesn't support the necessary reloc, it emits the following message
(gas/write.c:fixup_segment)
Error: can't resolve `.text' {.text section} - `.L13' {.rodata section}
May I suggest it would be good to make the messages consistent between
assembler and linker?
cheers,
DaveK
--
Can't think of a witty .sigline today....