[llvm-commits] [lld] Support reading archive libraries

Shankar Easwaran shankare at codeaurora.org
Fri Nov 2 11:55:17 PDT 2012


Hi Nick,
>> The ReaderArchiveOptions gets constructed using the command line 
>> flags thats passed to lld, along with the Reader. For the 
>> ReaderArchiveOptions to be created within ReaderELF,
>>  the command line options (or) the appropriate flags that were read 
>> from the command line would be needed.
>>
>> Currently all the Readers(createReader*) take in ReaderOptionsELF only.
>
>
> You just defined class ReaderOptionsArchive with one constructor:
>
>      ReaderOptionsArchive(Reader *reader, int argc, char *argv[]);
>
> but it never uses the command line args.   Why not add another 
> constructor:

I was going and planning to add a command line flag 
-whole-archive(similiar to the ld option) and construct the 
ReaderArchiveOptions based on that information.

I will change ReaderELF so that it takes ReaderArchiveOptions along with 
ReaderELFOptions.

>
>      ReaderOptionsArchive(Reader *reader);
>
> Other readers can use that constructor until the command line option 
> handling is worked out.

Ok, will add that interface.

When the command line options need to be handled, wouldnt this have a 
problem ?

Thanks

Shankar Easwaran

-- 
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, hosted by the Linux Foundation




More information about the llvm-commits mailing list