Date: Tue, 20 Jan 2015 17:00:29 +0000 (UTC) From: Sean Bruno <sbruno@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r277423 - head/contrib/llvm/tools/clang/lib/Driver Message-ID: <201501201700.t0KH0TiR012516@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: sbruno Date: Tue Jan 20 17:00:28 2015 New Revision: 277423 URL: https://svnweb.freebsd.org/changeset/base/277423 Log: Allow clang to be built for mips/mips64 backend types by adding our mips triple ids This only allows testing and does not change the defaults for mips/mips64. They still build/use gcc by default. Differential Revision: https://reviews.freebsd.org/D1190 Reviewed by: dim Modified: head/contrib/llvm/tools/clang/lib/Driver/Tools.cpp Modified: head/contrib/llvm/tools/clang/lib/Driver/Tools.cpp ============================================================================== --- head/contrib/llvm/tools/clang/lib/Driver/Tools.cpp Tue Jan 20 16:30:02 2015 (r277422) +++ head/contrib/llvm/tools/clang/lib/Driver/Tools.cpp Tue Jan 20 17:00:28 2015 (r277423) @@ -6587,6 +6587,17 @@ void freebsd::Link::ConstructJob(Compila CmdArgs.push_back("elf32ppc_fbsd"); } + if (Arg *A = Args.getLastArg(options::OPT_G)) { + if (ToolChain.getArch() == llvm::Triple::mips || + ToolChain.getArch() == llvm::Triple::mipsel || + ToolChain.getArch() == llvm::Triple::mips64 || + ToolChain.getArch() == llvm::Triple::mips64el) { + StringRef v = A->getValue(); + CmdArgs.push_back(Args.MakeArgString("-G" + v)); + A->claim(); + } + } + if (Output.isFilename()) { CmdArgs.push_back("-o"); CmdArgs.push_back(Output.getFilename());
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201501201700.t0KH0TiR012516>