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: Partial symbol export vs --export-dynamic


Hi Jean-Francois,

> - does the ELF format on Linux support exporting only some of the
>   application symbols, or does it have to all-or-nothing?

The ELF format does support exporting only some of an applications
symbols.

> - how painful would it be for me to add this functionality to
>   ld/bfd, or is this a project way beyond the scope of a binutils
>   novice? 

BFD can be a tricky place for a novice, so I would not recommend it as
a first project.  As an alternative though, you might like to consider
using the OBJCOPY program.  A recent patch to this program gave it the
ability to selectively convert global symbols into local symbols, (the
--localize-symbols command line switch).  With this you could use
--export-dynamic switch to ld first and then --localize-symbols to
objcopy to remove those symbols that you do not want to be exported.

Cheers
        Nick


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