This is the mail archive of the binutils@sourceware.org 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: how to add the contents of an elf file into another elf file?


On 11 December 2007 03:34, ?? wrote:

> Hi all,
> 
>    I have 2 .o files: a.o, b.o, which will be linked with other libs
> to generate an exeutable file.
>    I would like the contents of b.o as a whole to be an independant
> part of the executable file. b.o contains data and instructions which
> will be created as a process at runtime( embedded target ).
>    How can I do this?

  One solution would be to use objcopy to rename the sections in b.o to some new
names, then use a custom linker script to group them in a single output section
together, bracketed by start and end symbols.


    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]