<div dir="ltr">The original motivation for organizing things this way was to try and always be in the situation where, when linking against the latest deployment target, we should never need the extra library (because the content will be present in libSystem). This is useful in helping to ensure we don't unnecessarily embed copies of system provided functions.<div><br></div><div>I know it is quite cumbersome to maintain that policy, but have we explicitly given it up? Nick, what is your opinion here?</div><div><div><br></div><div> - Daniel</div></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Aug 15, 2016 at 3:51 PM, Chris Bieneman <span dir="ltr"><<a href="mailto:beanz@apple.com" target="_blank">beanz@apple.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">beanz created this revision.<br>
beanz added reviewers: ddunbar, bob.wilson.<br>
beanz added a subscriber: cfe-commits.<br>
<br>
The eprintf library was added before the general OS X builtins library existed as a place to store one builtin function. Since we have for several years had an actual mandated builtin library for OS X > 10.5, we should just merge eprintf into the main library.<br>
<br>
This change will resolve PR28855.<br>
<br>
As a follow up I'll also patch compiler-rt to not generate the eprintf library anymore.<br>
<br>
<a href="https://reviews.llvm.org/D23531" rel="noreferrer" target="_blank">https://reviews.llvm.org/<wbr>D23531</a><br>
<br>
Files:<br>
  lib/Driver/ToolChains.cpp<br>
<br>
Index: lib/Driver/ToolChains.cpp<br>
==============================<wbr>==============================<wbr>=======<br>
--- lib/Driver/ToolChains.cpp<br>
+++ lib/Driver/ToolChains.cpp<br>
@@ -483,8 +483,6 @@<br>
     if (isMacosxVersionLT(10, 5)) {<br>
       AddLinkRuntimeLib(Args, CmdArgs, "libclang_rt.10.4.a");<br>
     } else {<br>
-      if (getTriple().getArch() == llvm::Triple::x86)<br>
-        AddLinkRuntimeLib(Args, CmdArgs, "libclang_rt.eprintf.a");<br>
       AddLinkRuntimeLib(Args, CmdArgs, "libclang_rt.osx.a");<br>
     }<br>
   }<br>
<br>
<br>
</blockquote></div><br></div>