Date: Sat, 5 Sep 2015 00:20:57 +0000 (UTC) From: Brooks Davis <brooks@FreeBSD.org> To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r396153 - in head/devel/llvm37: . files Message-ID: <201509050020.t850KvR8037984@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: brooks Date: Sat Sep 5 00:20:56 2015 New Revision: 396153 URL: https://svnweb.freebsd.org/changeset/ports/396153 Log: Accept -fformat-extensions as a no-op flag to clang. Submitted by: Sender Ghost <lightside@gmx.com> Added: head/devel/llvm37/files/clang-patch-fformat_extensions.diff (contents, props changed) Modified: head/devel/llvm37/Makefile Modified: head/devel/llvm37/Makefile ============================================================================== --- head/devel/llvm37/Makefile Fri Sep 4 23:42:55 2015 (r396152) +++ head/devel/llvm37/Makefile Sat Sep 5 00:20:56 2015 (r396153) @@ -2,6 +2,7 @@ PORTNAME= llvm DISTVERSION= 3.7.0 +PORTREVISION= 1 CATEGORIES= devel lang MASTER_SITES= http://llvm.org/${PRE_}releases/${LLVM_RELEASE}/${RCDIR} DISTNAME= ${PORTNAME}-${DISTVERSION}.src @@ -38,6 +39,7 @@ OPTIONS_SUB= yes CLANG_DESC= Build clang CLANG_EXTRA_PATCHES= \ + ${PATCHDIR}/clang-patch-fformat_extensions.diff \ ${PATCHDIR}/clang-patch-tools_clang_lib_Headers_CMakeLists.txt CLANG_CONFLICTS_INSTALL= clang-devel-3.[1234567]* CLANG_DISTFILES= cfe-${DISTVERSION}.src${EXTRACT_SUFX} Added: head/devel/llvm37/files/clang-patch-fformat_extensions.diff ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/devel/llvm37/files/clang-patch-fformat_extensions.diff Sat Sep 5 00:20:56 2015 (r396153) @@ -0,0 +1,45 @@ +diff -ruN tools/clang/include/clang/Basic/LangOptions.def tools/clang/include/clang/Basic/LangOptions.def +--- tools/clang/include/clang/Basic/LangOptions.def 2015-07-30 22:47:41 UTC ++++ tools/clang/include/clang/Basic/LangOptions.def +@@ -114,6 +114,7 @@ + LANGOPT(RTTIData , 1, 1, "emit run-time type information data") + LANGOPT(MSBitfields , 1, 0, "Microsoft-compatible structure layout") + LANGOPT(Freestanding, 1, 0, "freestanding implementation") ++LANGOPT(FormatExtensions , 1, 0, "FreeBSD format extensions") + LANGOPT(NoBuiltin , 1, 0, "disable builtin functions") + LANGOPT(NoMathBuiltin , 1, 0, "disable math builtin functions") + LANGOPT(GNUAsm , 1, 1, "GNU-style inline assembly") +diff -ruN tools/clang/include/clang/Driver/Options.td tools/clang/include/clang/Driver/Options.td +--- tools/clang/include/clang/Driver/Options.td 2015-07-30 22:47:41 UTC ++++ tools/clang/include/clang/Driver/Options.td +@@ -644,6 +644,8 @@ + + def ffreestanding : Flag<["-"], "ffreestanding">, Group<f_Group>, Flags<[CC1Option]>, + HelpText<"Assert that the compilation takes place in a freestanding environment">; ++def fformat_extensions: Flag<["-"], "fformat-extensions">, Group<f_Group>, Flags<[CC1Option]>, ++ HelpText<"Enable FreeBSD kernel specific format string extensions">; + def fgnu_keywords : Flag<["-"], "fgnu-keywords">, Group<f_Group>, Flags<[CC1Option]>, + HelpText<"Allow GNU-extension keywords regardless of language standard">; + def fgnu89_inline : Flag<["-"], "fgnu89-inline">, Group<f_Group>, Flags<[CC1Option]>, +diff -ruN tools/clang/lib/Driver/Tools.cpp tools/clang/lib/Driver/Tools.cpp +--- tools/clang/lib/Driver/Tools.cpp 2015-07-30 22:47:41 UTC ++++ tools/clang/lib/Driver/Tools.cpp +@@ -4045,6 +4045,7 @@ + + // Forward -f (flag) options which we can pass directly. + Args.AddLastArg(CmdArgs, options::OPT_femit_all_decls); ++ Args.AddLastArg(CmdArgs, options::OPT_fformat_extensions); + Args.AddLastArg(CmdArgs, options::OPT_fheinous_gnu_extensions); + Args.AddLastArg(CmdArgs, options::OPT_fstandalone_debug); + Args.AddLastArg(CmdArgs, options::OPT_fno_standalone_debug); +diff -ruN tools/clang/lib/Frontend/CompilerInvocation.cpp tools/clang/lib/Frontend/CompilerInvocation.cpp +--- tools/clang/lib/Frontend/CompilerInvocation.cpp 2015-07-30 22:47:41 UTC ++++ tools/clang/lib/Frontend/CompilerInvocation.cpp +@@ -1543,6 +1543,7 @@ + Opts.ShortWChar = Args.hasFlag(OPT_fshort_wchar, OPT_fno_short_wchar, false); + Opts.ShortEnums = Args.hasArg(OPT_fshort_enums); + Opts.Freestanding = Args.hasArg(OPT_ffreestanding); ++ Opts.FormatExtensions = Args.hasArg(OPT_fformat_extensions); + Opts.NoBuiltin = Args.hasArg(OPT_fno_builtin) || Opts.Freestanding; + Opts.NoMathBuiltin = Args.hasArg(OPT_fno_math_builtin); + Opts.AssumeSaneOperatorNew = !Args.hasArg(OPT_fno_assume_sane_operator_new);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201509050020.t850KvR8037984>