Author: hans Date: Thu Aug 18 12:56:48 2016 New Revision: 279103 URL: http://llvm.org/viewvc/llvm-project?rev=279103&view=rev Log: Merging r278988: ------------------------------------------------------------------------ r278988 | cbieneman | 2016-08-17 14:54:30 -0700 (Wed, 17 Aug 2016) | 14 lines
[Darwin] Stop linking libclang_rt.eprintf.a Summary: 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. This change will resolve PR28855. As a follow up I'll also patch compiler-rt to not generate the eprintf library anymore. Reviewers: ddunbar, bob.wilson Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D23531 ------------------------------------------------------------------------ Modified: cfe/branches/release_39/ (props changed) cfe/branches/release_39/lib/Driver/ToolChains.cpp Propchange: cfe/branches/release_39/ ------------------------------------------------------------------------------ --- svn:mergeinfo (original) +++ svn:mergeinfo Thu Aug 18 12:56:48 2016 @@ -1,4 +1,4 @@ /cfe/branches/type-system-rewrite:134693-134817 -/cfe/trunk:275880,275967,276102,276350,276361,276473,276653,276716,276887,276891,276900,276979,276983,277095,277138,277141,277221,277307,277522,277743,277783,277796-277797,277852,277866,277889,277900,278139,278156,278234-278235,278393,278395,278763,278786 +/cfe/trunk:275880,275967,276102,276350,276361,276473,276653,276716,276887,276891,276900,276979,276983,277095,277138,277141,277221,277307,277522,277743,277783,277796-277797,277852,277866,277889,277900,278139,278156,278234-278235,278393,278395,278763,278786,278988 /cfe/trunk/test:170344 /cfe/trunk/test/SemaTemplate:126920 Modified: cfe/branches/release_39/lib/Driver/ToolChains.cpp URL: http://llvm.org/viewvc/llvm-project/cfe/branches/release_39/lib/Driver/ToolChains.cpp?rev=279103&r1=279102&r2=279103&view=diff ============================================================================== --- cfe/branches/release_39/lib/Driver/ToolChains.cpp (original) +++ cfe/branches/release_39/lib/Driver/ToolChains.cpp Thu Aug 18 12:56:48 2016 @@ -474,21 +474,26 @@ void DarwinClang::AddLinkRuntimeLibArgs( else if (isMacosxVersionLT(10, 6)) CmdArgs.push_back("-lgcc_s.10.5"); - // For OS X, we thought we would only need a static runtime library when - // targeting 10.4, to provide versions of the static functions which were - // omitted from 10.4.dylib. + // Originally for OS X, we thought we would only need a static runtime + // library when targeting 10.4, to provide versions of the static functions + // which were omitted from 10.4.dylib. This led to the creation of the 10.4 + // builtins library. // // Unfortunately, that turned out to not be true, because Darwin system // headers can still use eprintf on i386, and it is not exported from // libSystem. Therefore, we still must provide a runtime library just for // the tiny tiny handful of projects that *might* use that symbol. - if (isMacosxVersionLT(10, 5)) { + // + // Then over time, we figured out it was useful to add more things to the + // runtime so we created libclang_rt.osx.a to provide new functions when + // deploying to old OS builds, and for a long time we had both eprintf and + // osx builtin libraries. Which just seems excessive. So with PR 28855, we + // are removing the eprintf library and expecting eprintf to be provided by + // the OS X builtins library. + if (isMacosxVersionLT(10, 5)) AddLinkRuntimeLib(Args, CmdArgs, "libclang_rt.10.4.a"); - } else { - if (getTriple().getArch() == llvm::Triple::x86) - AddLinkRuntimeLib(Args, CmdArgs, "libclang_rt.eprintf.a"); + else AddLinkRuntimeLib(Args, CmdArgs, "libclang_rt.osx.a"); - } } } _______________________________________________ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits