From 2ab1c1226fc083008a4852276e22c98c39188720 Mon Sep 17 00:00:00 2001 From: TB Schardl Date: Fri, 3 Jul 2020 23:30:57 -0400 Subject: [PATCH] [ToolChain] Better test to determine whether to use the --enable-new-dtags flag when linking the OpenCilk runtime --- clang/lib/Driver/ToolChain.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/clang/lib/Driver/ToolChain.cpp b/clang/lib/Driver/ToolChain.cpp index 0303f2863115..19fb2edf9199 100644 --- a/clang/lib/Driver/ToolChain.cpp +++ b/clang/lib/Driver/ToolChain.cpp @@ -1060,7 +1060,7 @@ static void addRuntimeRunPath(const ToolChain &TC, const ArgList &Args, CmdArgs.push_back("-rpath"); CmdArgs.push_back(Args.MakeArgString(CandidateRPath->c_str())); // TODO: Check the portability of the --enable-new-dtags flag. - if (!Triple.isOSDarwin()) + if (Triple.isOSBinFormatELF()) CmdArgs.push_back("--enable-new-dtags"); } }