On 06.07.2017 14:57, Joerg Sonnenberger wrote:
> On Tue, Jul 04, 2017 at 07:55:56PM -0000, Kamil Rytarowski via cfe-commits 
> wrote:
>> Modified: cfe/trunk/lib/Driver/ToolChains/CommonArgs.cpp
>> URL: 
>> http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Driver/ToolChains/CommonArgs.cpp?rev=307104&r1=307103&r2=307104&view=diff
>> ==============================================================================
>> --- cfe/trunk/lib/Driver/ToolChains/CommonArgs.cpp (original)
>> +++ cfe/trunk/lib/Driver/ToolChains/CommonArgs.cpp Tue Jul  4 12:55:56 2017
>> @@ -524,6 +524,7 @@ void tools::linkSanitizerRuntimeDeps(con
>>    CmdArgs.push_back("-lm");
>>    // There's no libdl on FreeBSD or RTEMS.
>>    if (TC.getTriple().getOS() != llvm::Triple::FreeBSD &&
>> +      TC.getTriple().getOS() != llvm::Triple::NetBSD &&
>>        TC.getTriple().getOS() != llvm::Triple::RTEMS)
>>      CmdArgs.push_back("-ldl");
>>  }
> 
> I'd really prefer if we switched to a positive list here, i.e. only link
> libdl on platforms that actually need it. I'm not sure who does, beside
> Linux.
> 
> Joerg
> 

I have no preference.

SunOS (at least SmartOS) ships with ldl. Most GNU systems (HURD, Linux,
KFREEBSD/GNU) use it too. I think the same applies for HPUX, AIX, IRIX
and Darwin?

There are more switches for the same purpose in the code, but for other
kind of instrumentation. At the moment NetBSD isn't used there.

Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to