diff options
author | Iru Cai <mytbk920423@gmail.com> | 2016-10-29 23:37:42 +0800 |
---|---|---|
committer | Martin Roth <martinroth@google.com> | 2017-03-05 18:35:18 +0100 |
commit | 03353de80b2c0604e778d81e9010af787a183ab3 (patch) | |
tree | 4621200302fe71537d6f1a07dd98c439bf783fd0 /util/crossgcc/patches/cfe-3.9.1.src_frontend.patch | |
parent | 0da186c3ffb1d9aa7433a5d0d5263aba7a25ad60 (diff) |
buildgcc: Update GCC, Binutils, GMP, MPFR, GDB, IASL and LLVM
- GCC gets updated from 5.2.0 to 6.3.0:
gcc-6.3.0_riscv.patch is a diff between 5fcb8c4 and 173684b in
riscv-gcc, and it needs gcc-6.3.0_memmodel.patch.
- Binutils goes from 2.26.1 to 2.28:
There is a build error for MIPS gold so I add patch for it.
- GMP gets a bump from 6.1.0 to 6.1.2
- MPFR is updated from 3.1.4 to 3.1.5
- GDB is upgraded from 6.1.1 to 6.1.2
- IASL is changed from 20160831 to 20161222
- LLVM is changed from 3.8.0 to 3.9.1
Change-Id: I20fea838d798c430d8c4d2cc6b07614d967c60c5
Signed-off-by: Iru Cai <mytbk920423@gmail.com>
Signed-off-by: Martin Roth <martinroth@google.com>
Reviewed-on: https://review.coreboot.org/17189
Tested-by: build bot (Jenkins)
Diffstat (limited to 'util/crossgcc/patches/cfe-3.9.1.src_frontend.patch')
-rw-r--r-- | util/crossgcc/patches/cfe-3.9.1.src_frontend.patch | 79 |
1 files changed, 79 insertions, 0 deletions
diff --git a/util/crossgcc/patches/cfe-3.9.1.src_frontend.patch b/util/crossgcc/patches/cfe-3.9.1.src_frontend.patch new file mode 100644 index 0000000000..3b8e6b70b7 --- /dev/null +++ b/util/crossgcc/patches/cfe-3.9.1.src_frontend.patch @@ -0,0 +1,79 @@ +Frontend driver patch from Edward O'Callaghan + +https://llvm.org/bugs/show_bug.cgi?id=21538 + +Index: include/clang/Driver/Driver.h +=================================================================== +--- cfe-3.7.1.src/include/clang/Driver/Driver.h (revision 211898) ++++ cfe-3.8.0.src/include/clang/Driver/Driver.h (working copy) +@@ -357,6 +357,14 @@ + // FIXME: This should be in CompilationInfo. + std::string GetFilePath(const char *Name, const ToolChain &TC) const; + ++ /// GetCompilerRTPath - Find Compiler-RT library path ++ /// ++ /// \param TC - The provided tool chain for additional information on ++ /// directories to search. ++ // ++ // FIXME: This should be in CompilationInfo. ++ std::string GetCompilerRTPath(const ToolChain &TC) const; ++ + /// GetProgramPath - Lookup \p Name in the list of program search paths. + /// + /// \param TC - The provided tool chain for additional information on +Index: include/clang/Driver/Options.td +=================================================================== +--- cfe-3.7.1.src/include/clang/Driver/Options.td (revision 211898) ++++ cfe-3.8.0.src/include/clang/Driver/Options.td (working copy) +@@ -1669,6 +1669,8 @@ + HelpText<"Enable Objective-C Ivar layout bitmap print trace">; + def print_libgcc_file_name : Flag<["-", "--"], "print-libgcc-file-name">, + HelpText<"Print the library path for \"libgcc.a\"">; ++def print_librt_file_name : Flag<["-", "--"], "print-librt-file-name">, ++ HelpText<"Print the library path for \"libclang_rt.builtins-ARCH.a\"">; + def print_multi_directory : Flag<["-", "--"], "print-multi-directory">; + def print_multi_lib : Flag<["-", "--"], "print-multi-lib">; + def print_multi_os_directory : Flag<["-", "--"], "print-multi-os-directory">; +Index: lib/Driver/Driver.cpp +=================================================================== +--- cfe-3.7.1.src/lib/Driver/Driver.cpp (revision 211898) ++++ cfe-3.8.0.src/lib/Driver/Driver.cpp (working copy) +@@ -910,6 +910,11 @@ + return false; + } + ++ if (C.getArgs().hasArg(options::OPT_print_librt_file_name)) { ++ llvm::outs() << GetCompilerRTPath(TC) << "\n"; ++ return false; ++ } ++ + if (C.getArgs().hasArg(options::OPT_print_multi_lib)) { + for (const Multilib &Multilib : TC.getMultilibs()) + llvm::outs() << Multilib << "\n"; +@@ -2153,6 +2158,26 @@ + return false; + } + ++std::string Driver::GetCompilerRTPath(const ToolChain &TC) const { ++ // The runtimes are located in the OS-specific resource directory. ++ SmallString<128> Res(TC.getDriver().ResourceDir); ++ const llvm::Triple &Triple = TC.getTriple(); ++ ++ // TC.getOS() yield "freebsd10.0" whereas "freebsd" is expected. ++ StringRef OSLibName = (Triple.getOS() == llvm::Triple::FreeBSD) ? ++ "freebsd" : TC.getOS(); ++ llvm::sys::path::append(Res, "lib", OSLibName); ++ ++ StringRef archName = TC.getArchName(); ++ // Until ARM libraries are build separately, we have them all in one library ++ if (TC.getArch() == llvm::Triple::arm || ++ TC.getArch() == llvm::Triple::armeb) ++ archName = "arm"; ++ ++ llvm::sys::path::append(Res, Twine("libclang_rt.builtins-") + archName + ".a"); ++ return Res.str(); ++} ++ + std::string Driver::GetProgramPath(const char *Name, + const ToolChain &TC) const { + SmallVector<std::string, 2> TargetSpecificExecutables; |