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]

Re: Re[2]: ld: Not enough room for program headers


Franco Broi wrote:
> 
> 
> I tried to change the script, but ld was using an internal script.
> When I made it use one of the scripts in lib/ldscripts, I got other
> errors about bad MRI in OUTPUT_FORMAT or something. Even when I
> extracted the script it was using (using --verbose) it would still
> produce an error when reading it back unchanged.

Franco,
could you please show _precisely_ what you were doing and how?  I tried
to repeat on my Alpha roughly what you described and things do work for
me, i.e. I can read back a linker script extracted from --verbose output
and this works fine without giving me any errors at all.

Also on a "hello world!" program I tried to link using a modified
script where I put 
     . = 0x120000000 + SIZEOF_HEADERS + 0x100;
with "0x100" is some bogus number just to move a section start
ahead.  When linking with '-M --verbose' I see, among other things,

GNU ld version 2.10.90 (with BFD 2.10.0.9)
.....

Linker script and memory map
          0x0000000120000290      .=((0x120000000+SIZEOF_HEADERS)+0x100)
.....

so, obviously, this is my modified script which is used.  Moreover
an executable linked that way still prints "hello world!".

   Best regards,
   Michal
   michal@harddata.com

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