[lld] r217112 - If lld binary is named 'ld' on darwin, use darwin driver mode

Shankar Easwaran shankare at codeaurora.org
Mon Sep 8 11:19:07 PDT 2014


On 9/8/2014 12:13 PM, Nick Kledzik wrote:
> On Sep 7, 2014, at 9:36 PM, Shankar Easwaran <shankare at codeaurora.org> wrote:
>
>> On 9/5/2014 8:41 PM, Nick Kledzik wrote:
>>> It would only be a problem if you built the lld binary on MacOSX, renamed it to "x86_86-netbsd-ld” than ran it and expected it to behave as a gnu linker.
>>>
>>> If you think that is a valid configuration, I can move the #if __APPLE_ check out of strToFlavor(), and instead inside UniversalDriver::link() do a check if argv[0] is exactly “ld” inside  #if __APPLE_ .
>> We could parse the target triple in the Universal driver, and check the triple if its triple.isOSDarwin() ??
> That would be an additional feature (“darwin” or “apple” in triple means use ld64 command line parser).  The case I’m concerned with is when there is no triple and the tool name is just “ld”
Agree.

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




More information about the llvm-commits mailing list