This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

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....
 



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]