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: Building symbol table


On Wed, Nov 14, 2012 at 02:08:36PM +0100, Jan Smets wrote:
> I was exploring different ideas:
>  a) include the .symtab/etc sections in my data segment and use a
> linker script to PROVIDE() pointers to the beginning/end of the
> tables.
>     This didn't work.
> 
>  b) Make a binary dump of the .shstrtab/.symtab/.strtab sections of
> my ELF executable and push that binary data to my board in a similar
> way as my text/data segments.
> 
>   I was hoping that  objcopy  -j .strtab -j .symtab <in> <out> -O
> binary would get my that.

No, this approach won't work.  Special sections like these are not
seen by BFD as being sections in the usual sense, so objdump, objcopy,
ld etc. can't manipulate them like .text or .data.

-- 
Alan Modra
Australia Development Lab, IBM


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