diff options
author | brooks <brooks@FreeBSD.org> | 2012-09-15 05:03:34 +0800 |
---|---|---|
committer | brooks <brooks@FreeBSD.org> | 2012-09-15 05:03:34 +0800 |
commit | ba3f6da37b9fe2453128777b3063d93829a716fb (patch) | |
tree | 1e79a36569766e66ec472659b7d57a83a01a3bb8 /lang | |
parent | 41ad74642e63539c2bf0aa80cbac22d60bb41a0f (diff) | |
download | freebsd-ports-gnome-ba3f6da37b9fe2453128777b3063d93829a716fb.tar.gz freebsd-ports-gnome-ba3f6da37b9fe2453128777b3063d93829a716fb.tar.zst freebsd-ports-gnome-ba3f6da37b9fe2453128777b3063d93829a716fb.zip |
Upgrade to svn rev r163622. Several fixes to FreeBSD support for -pie and
mips as well as reported improvements to the MIPS backend.
Diffstat (limited to 'lang')
-rw-r--r-- | lang/clang-devel/distinfo | 8 | ||||
-rw-r--r-- | lang/clang-devel/files/patch-tools_clang_lib_Driver_Tools.cpp | 205 | ||||
-rw-r--r-- | lang/clang-devel/pkg-plist | 35 |
3 files changed, 27 insertions, 221 deletions
diff --git a/lang/clang-devel/distinfo b/lang/clang-devel/distinfo index f88af1eda5bd..ead42d2d0a11 100644 --- a/lang/clang-devel/distinfo +++ b/lang/clang-devel/distinfo @@ -1,4 +1,4 @@ -SHA256 (clang-3.2.r162438.tar.bz2) = 477e78674c428218ddd717e3faa798daf040ba43e26c538ef0f733dab1d4fbe1 -SIZE (clang-3.2.r162438.tar.bz2) = 7193019 -SHA256 (llvm-3.2.r162438.tar.bz2) = 6e5bd1121b6af1e89ace5f799febeec8278fa2e24fce6f69f5d840a42ac75617 -SIZE (llvm-3.2.r162438.tar.bz2) = 8851337 +SHA256 (clang-3.2.r163622.tar.bz2) = 29e31eea6697248a56e2dcd3b2318798d3cb7dff089f1453e7ab55c988c7bbeb +SIZE (clang-3.2.r163622.tar.bz2) = 7277330 +SHA256 (llvm-3.2.r163622.tar.bz2) = 12cdd4eb5d3ee236f531be7c297889a251463033504c465b6267aac22baab9f8 +SIZE (llvm-3.2.r163622.tar.bz2) = 8961570 diff --git a/lang/clang-devel/files/patch-tools_clang_lib_Driver_Tools.cpp b/lang/clang-devel/files/patch-tools_clang_lib_Driver_Tools.cpp deleted file mode 100644 index 22c6e7d3301e..000000000000 --- a/lang/clang-devel/files/patch-tools_clang_lib_Driver_Tools.cpp +++ /dev/null @@ -1,205 +0,0 @@ - -$FreeBSD$ - ---- tools/clang/lib/Driver/Tools.cpp.orig -+++ tools/clang/lib/Driver/Tools.cpp -@@ -5119,17 +5119,48 @@ - - // When building 32-bit code on FreeBSD/amd64, we have to explicitly - // instruct as in the base system to assemble 32-bit code. -- if (getToolChain().getArchName() == "i386") -+ if (getToolChain().getArch() == llvm::Triple::x86) - CmdArgs.push_back("--32"); -- -- if (getToolChain().getArchName() == "powerpc") -+ else if (getToolChain().getArch() == llvm::Triple::ppc) - CmdArgs.push_back("-a32"); -+ else if (getToolChain().getArch() == llvm::Triple::mips || -+ getToolChain().getArch() == llvm::Triple::mipsel || -+ getToolChain().getArch() == llvm::Triple::mips64 || -+ getToolChain().getArch() == llvm::Triple::mips64el) { -+ StringRef CPUName; -+ StringRef ABIName; -+ getMipsCPUAndABI(Args, getToolChain(), CPUName, ABIName); - -- // Set byte order explicitly -- if (getToolChain().getArchName() == "mips") -- CmdArgs.push_back("-EB"); -- else if (getToolChain().getArchName() == "mipsel") -- CmdArgs.push_back("-EL"); -+ CmdArgs.push_back("-march"); -+ CmdArgs.push_back(CPUName.data()); -+ -+ // Convert ABI name to the GNU tools acceptable variant. -+ if (ABIName == "o32") -+ ABIName = "32"; -+ else if (ABIName == "n64") -+ ABIName = "64"; -+ -+ CmdArgs.push_back("-mabi"); -+ CmdArgs.push_back(ABIName.data()); -+ -+ if (getToolChain().getArch() == llvm::Triple::mips || -+ getToolChain().getArch() == llvm::Triple::mips64) -+ CmdArgs.push_back("-EB"); -+ else -+ CmdArgs.push_back("-EL"); -+ -+ Arg *LastPICArg = Args.getLastArg(options::OPT_fPIC, options::OPT_fno_PIC, -+ options::OPT_fpic, options::OPT_fno_pic, -+ options::OPT_fPIE, options::OPT_fno_PIE, -+ options::OPT_fpie, options::OPT_fno_pie); -+ if (LastPICArg && -+ (LastPICArg->getOption().matches(options::OPT_fPIC) || -+ LastPICArg->getOption().matches(options::OPT_fpic) || -+ LastPICArg->getOption().matches(options::OPT_fPIE) || -+ LastPICArg->getOption().matches(options::OPT_fpie))) { -+ CmdArgs.push_back("-KPIC"); -+ } -+ } - - Args.AddAllArgValues(CmdArgs, options::OPT_Wa_COMMA, - options::OPT_Xassembler); -@@ -5153,7 +5184,9 @@ - const InputInfoList &Inputs, - const ArgList &Args, - const char *LinkingOutput) const { -- const Driver &D = getToolChain().getDriver(); -+ const toolchains::Linux& ToolChain = -+ static_cast<const toolchains::Linux&>(getToolChain()); -+ const Driver &D = ToolChain.getDriver(); - ArgStringList CmdArgs; - - // Silence warning for "clang -g foo.o -o foo" -@@ -5167,6 +5200,9 @@ - if (!D.SysRoot.empty()) - CmdArgs.push_back(Args.MakeArgString("--sysroot=" + D.SysRoot)); - -+ if (Args.hasArg(options::OPT_pie)) -+ CmdArgs.push_back("-pie"); -+ - if (Args.hasArg(options::OPT_static)) { - CmdArgs.push_back("-Bstatic"); - } else { -@@ -5179,8 +5215,8 @@ - CmdArgs.push_back("-dynamic-linker"); - CmdArgs.push_back("/libexec/ld-elf.so.1"); - } -- if (getToolChain().getTriple().getOSMajorVersion() >= 9) { -- llvm::Triple::ArchType Arch = getToolChain().getArch(); -+ if (ToolChain.getTriple().getOSMajorVersion() >= 9) { -+ llvm::Triple::ArchType Arch = ToolChain.getArch(); - if (Arch == llvm::Triple::arm || Arch == llvm::Triple::sparc || - Arch == llvm::Triple::x86 || Arch == llvm::Triple::x86_64) { - CmdArgs.push_back("--hash-style=both"); -@@ -5191,12 +5227,12 @@ - - // When building 32-bit code on FreeBSD/amd64, we have to explicitly - // instruct ld in the base system to link 32-bit code. -- if (getToolChain().getArchName() == "i386") { -+ if (ToolChain.getArchName() == "i386") { - CmdArgs.push_back("-m"); - CmdArgs.push_back("elf_i386_fbsd"); - } - -- if (getToolChain().getArchName() == "powerpc") { -+ if (ToolChain.getArchName() == "powerpc") { - CmdArgs.push_back("-m"); - CmdArgs.push_back("elf32ppc_fbsd"); - } -@@ -5210,29 +5246,32 @@ - - if (!Args.hasArg(options::OPT_nostdlib) && - !Args.hasArg(options::OPT_nostartfiles)) { -- if (!Args.hasArg(options::OPT_shared)) { -+ const char *crt1 = NULL; -+ if (!Args.hasArg(options::OPT_shared)){ - if (Args.hasArg(options::OPT_pg)) -- CmdArgs.push_back(Args.MakeArgString( -- getToolChain().GetFilePath("gcrt1.o"))); -- else { -- const char *crt = Args.hasArg(options::OPT_pie) ? "Scrt1.o" : "crt1.o"; -- CmdArgs.push_back(Args.MakeArgString( -- getToolChain().GetFilePath(crt))); -- } -- CmdArgs.push_back(Args.MakeArgString( -- getToolChain().GetFilePath("crti.o"))); -- CmdArgs.push_back(Args.MakeArgString( -- getToolChain().GetFilePath("crtbegin.o"))); -- } else { -- CmdArgs.push_back(Args.MakeArgString( -- getToolChain().GetFilePath("crti.o"))); -- CmdArgs.push_back(Args.MakeArgString( -- getToolChain().GetFilePath("crtbeginS.o"))); -+ crt1 = "gcrt1.o"; -+ else if (Args.hasArg(options::OPT_pie)) -+ crt1 = "Scrt1.o"; -+ else -+ crt1 = "crt1.o"; - } -+ if (crt1) -+ CmdArgs.push_back(Args.MakeArgString(ToolChain.GetFilePath(crt1))); -+ -+ CmdArgs.push_back(Args.MakeArgString(ToolChain.GetFilePath("crti.o"))); -+ -+ const char *crtbegin; -+ if (Args.hasArg(options::OPT_static)) -+ crtbegin = "crtbeginT.o"; -+ else if (Args.hasArg(options::OPT_shared) || Args.hasArg(options::OPT_pie)) -+ crtbegin = "crtbeginS.o"; -+ else -+ crtbegin = "crtbegin.o"; -+ CmdArgs.push_back(Args.MakeArgString(ToolChain.GetFilePath(crtbegin))); - } - - Args.AddAllArgs(CmdArgs, options::OPT_L); -- const ToolChain::path_list Paths = getToolChain().getFilePaths(); -+ const ToolChain::path_list Paths = ToolChain.getFilePaths(); - for (ToolChain::path_list::const_iterator i = Paths.begin(), e = Paths.end(); - i != e; ++i) - CmdArgs.push_back(Args.MakeArgString(StringRef("-L") + *i)); -@@ -5243,12 +5282,12 @@ - Args.AddAllArgs(CmdArgs, options::OPT_Z_Flag); - Args.AddAllArgs(CmdArgs, options::OPT_r); - -- AddLinkerInputs(getToolChain(), Inputs, Args, CmdArgs); -+ AddLinkerInputs(ToolChain, Inputs, Args, CmdArgs); - - if (!Args.hasArg(options::OPT_nostdlib) && - !Args.hasArg(options::OPT_nodefaultlibs)) { - if (D.CCCIsCXX) { -- getToolChain().AddCXXStdlibLibArgs(Args, CmdArgs); -+ ToolChain.AddCXXStdlibLibArgs(Args, CmdArgs); - if (Args.hasArg(options::OPT_pg)) - CmdArgs.push_back("-lm_p"); - else -@@ -5301,20 +5340,20 @@ - - if (!Args.hasArg(options::OPT_nostdlib) && - !Args.hasArg(options::OPT_nostartfiles)) { -- if (!Args.hasArg(options::OPT_shared)) -- CmdArgs.push_back(Args.MakeArgString(getToolChain().GetFilePath( -- "crtend.o"))); -+ const char *crtend; -+ if (Args.hasArg(options::OPT_shared) || Args.hasArg(options::OPT_pie)) -+ crtend = "crtendS.o"; - else -- CmdArgs.push_back(Args.MakeArgString(getToolChain().GetFilePath( -- "crtendS.o"))); -- CmdArgs.push_back(Args.MakeArgString(getToolChain().GetFilePath( -- "crtn.o"))); -+ crtend = "crtend.o"; -+ -+ CmdArgs.push_back(Args.MakeArgString(ToolChain.GetFilePath(crtend))); -+ CmdArgs.push_back(Args.MakeArgString(ToolChain.GetFilePath("crtn.o"))); - } - -- addProfileRT(getToolChain(), Args, CmdArgs, getToolChain().getTriple()); -+ addProfileRT(ToolChain, Args, CmdArgs, ToolChain.getTriple()); - - const char *Exec = -- Args.MakeArgString(getToolChain().GetProgramPath("ld")); -+ Args.MakeArgString(ToolChain.GetProgramPath("ld")); - C.addCommand(new Command(JA, *this, Exec, CmdArgs)); - } - diff --git a/lang/clang-devel/pkg-plist b/lang/clang-devel/pkg-plist index 5a6e64cdef82..52ac3dcafc7c 100644 --- a/lang/clang-devel/pkg-plist +++ b/lang/clang-devel/pkg-plist @@ -31,8 +31,11 @@ include/clang/AST/CanonicalType.h include/clang/AST/CharUnits.h include/clang/AST/Comment.h include/clang/AST/CommentBriefParser.h +include/clang/AST/CommentCommandInfo.inc include/clang/AST/CommentCommandTraits.h include/clang/AST/CommentDiagnostic.h +include/clang/AST/CommentHTMLTags.inc +include/clang/AST/CommentHTMLTagsProperties.inc include/clang/AST/CommentLexer.h include/clang/AST/CommentNodes.inc include/clang/AST/CommentParser.h @@ -93,6 +96,7 @@ include/clang/ASTMatchers/ASTMatchFinder.h include/clang/ASTMatchers/ASTMatchers.h include/clang/ASTMatchers/ASTMatchersInternal.h include/clang/ASTMatchers/ASTMatchersMacros.h +include/clang/ASTMatchers/ASTTypeTraits.h include/clang/Analysis/Analyses/CFGReachabilityAnalysis.h include/clang/Analysis/Analyses/Dominators.h include/clang/Analysis/Analyses/FormatString.h @@ -214,8 +218,6 @@ include/clang/Edit/FileOffset.h include/clang/Edit/Rewriters.h include/clang/Frontend/ASTConsumers.h include/clang/Frontend/ASTUnit.h -include/clang/Frontend/Analyses.def -include/clang/Frontend/AnalyzerOptions.h include/clang/Frontend/ChainedDiagnosticConsumer.h include/clang/Frontend/ChainedIncludesSource.h include/clang/Frontend/CodeGenOptions.h @@ -274,15 +276,15 @@ include/clang/Parse/AttrLateParsed.inc include/clang/Parse/ParseAST.h include/clang/Parse/ParseDiagnostic.h include/clang/Parse/Parser.h -include/clang/Rewrite/ASTConsumers.h -include/clang/Rewrite/DeltaTree.h -include/clang/Rewrite/FixItRewriter.h -include/clang/Rewrite/FrontendActions.h -include/clang/Rewrite/HTMLRewrite.h -include/clang/Rewrite/RewriteRope.h -include/clang/Rewrite/Rewriter.h -include/clang/Rewrite/Rewriters.h -include/clang/Rewrite/TokenRewriter.h +include/clang/Rewrite/Core/DeltaTree.h +include/clang/Rewrite/Core/HTMLRewrite.h +include/clang/Rewrite/Core/RewriteRope.h +include/clang/Rewrite/Core/Rewriter.h +include/clang/Rewrite/Core/TokenRewriter.h +include/clang/Rewrite/Frontend/ASTConsumers.h +include/clang/Rewrite/Frontend/FixItRewriter.h +include/clang/Rewrite/Frontend/FrontendActions.h +include/clang/Rewrite/Frontend/Rewriters.h include/clang/Sema/AnalysisBasedWarnings.h include/clang/Sema/AttrParsedAttrKinds.inc include/clang/Sema/AttrParsedAttrList.inc @@ -328,6 +330,8 @@ include/clang/Serialization/SerializationDiagnostic.h include/clang/StaticAnalyzer/Checkers/ClangCheckers.h include/clang/StaticAnalyzer/Checkers/CommonBugCategories.h include/clang/StaticAnalyzer/Checkers/LocalCheckers.h +include/clang/StaticAnalyzer/Core/Analyses.def +include/clang/StaticAnalyzer/Core/AnalyzerOptions.h include/clang/StaticAnalyzer/Core/BugReporter/BugReporter.h include/clang/StaticAnalyzer/Core/BugReporter/BugReporterVisitor.h include/clang/StaticAnalyzer/Core/BugReporter/BugType.h @@ -346,6 +350,7 @@ include/clang/StaticAnalyzer/Core/PathSensitive/CheckerContext.h include/clang/StaticAnalyzer/Core/PathSensitive/CheckerHelpers.h include/clang/StaticAnalyzer/Core/PathSensitive/ConstraintManager.h include/clang/StaticAnalyzer/Core/PathSensitive/CoreEngine.h +include/clang/StaticAnalyzer/Core/PathSensitive/DynamicTypeInfo.h include/clang/StaticAnalyzer/Core/PathSensitive/Environment.h include/clang/StaticAnalyzer/Core/PathSensitive/ExplodedGraph.h include/clang/StaticAnalyzer/Core/PathSensitive/ExprEngine.h @@ -369,6 +374,8 @@ include/clang/StaticAnalyzer/Frontend/FrontendActions.h include/clang/Tooling/ArgumentsAdjusters.h include/clang/Tooling/CommonOptionsParser.h include/clang/Tooling/CompilationDatabase.h +include/clang/Tooling/CompilationDatabasePluginRegistry.h +include/clang/Tooling/JSONCompilationDatabase.h include/clang/Tooling/Refactoring.h include/clang/Tooling/RefactoringCallbacks.h include/clang/Tooling/Tooling.h @@ -400,7 +407,8 @@ lib/libclangFrontend.a lib/libclangFrontendTool.a lib/libclangLex.a lib/libclangParse.a -lib/libclangRewrite.a +lib/libclangRewriteCore.a +lib/libclangRewriteFrontend.a lib/libclangSema.a lib/libclangSerialization.a lib/libclangStaticAnalyzerCheckers.a @@ -421,6 +429,7 @@ lib/libclangTooling.a %%PORTDOCS%%%%DOCSDIR%%/html/IntroductionToTheClangAST.html %%PORTDOCS%%%%DOCSDIR%%/html/JSONCompilationDatabase.html %%PORTDOCS%%%%DOCSDIR%%/html/LanguageExtensions.html +%%PORTDOCS%%%%DOCSDIR%%/html/LibASTMatchers.html %%PORTDOCS%%%%DOCSDIR%%/html/LibASTMatchersReference.html %%PORTDOCS%%%%DOCSDIR%%/html/LibTooling.html %%PORTDOCS%%%%DOCSDIR%%/html/ObjectiveCLiterals.html @@ -453,6 +462,8 @@ lib/libclangTooling.a @dirrm include/clang/StaticAnalyzer @dirrm include/clang/Serialization @dirrm include/clang/Sema +@dirrm include/clang/Rewrite/Frontend +@dirrm include/clang/Rewrite/Core @dirrm include/clang/Rewrite @dirrm include/clang/Parse @dirrm include/clang/Lex |