[libc++][patch] Sort out common Linux linking issues.
Sebastian Redl
sebastian.redl at getdesigned.at
Wed Apr 9 05:52:56 PDT 2014
Gentle ping on this. Haven't heard anything except that Marshall likes the documentation.
On Apr 2, 2014, at 10:54, Dmitri Gribenko wrote:
> + Sylvestre Ledru
>
> On Tue, Apr 1, 2014 at 6:37 PM, Sebastian Redl
> <sebastian.redl at getdesigned.at> wrote:
>> Following the recent inquiry and David Chisnall's advice, I have created
>> a patch that makes libc++ work a lot smoother on Linux. It allows a
>> plain "clang++ -stdlib=libc++" command line to work no matter what ABI
>> library is used, and fixes the linking errors I encountered.
>>
>> However, I have absolutely no idea what it does on other platforms.
>>
>> Log Message:
>>
>> Sort out common Linux linking issues.
>>
>> Using libc++ on Linux was problematic because using libsupc++ didn't
>> pull in
>> all necessary symbols, whereas linking against a dynamic ABI library
>> required
>> the user to explicitly link against the ABI library.
>>
>> This patch adds a new property, LIBCXX_CXX_ABI_LINK, that can be set
>> to dynamic
>> (the default) or static. In dynamic mode, it links against the
>> dynamic library,
>> and substitutes its unversioned .so file with a linker script that links
>> against both libc++ and the ABI library. In static mode, it uses
>> --whole-archive
>> to force inclusion of the entire ABI library into the libc++.so.
>>
>> It also automatically uses libstdc++ for dynamic mode and libsupc++
>> for static
>> mode if either was selected; the two ABI names are now synonyms.
>>
>> _______________________________________________
>> cfe-commits mailing list
>> cfe-commits at cs.uiuc.edu
>> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits
>>
>
>
>
> --
> main(i,j){for(i=2;;i++){for(j=2;j<i;j++){if(!(i%j)){j=0;break;}}if
> (j){printf("%d\n",i);}}} /*Dmitri Gribenko <gribozavr at gmail.com>*/
More information about the cfe-commits
mailing list