diff --git a/0007-add-more-warning-options-to-fgcc-compatible.patch b/0007-add-more-warning-options-to-fgcc-compatible.patch index 3d73889ecad4b35b9eb340edf9be2a93c58e5004..c25bfba062680225578a8a068683a863a623e2bf 100644 --- a/0007-add-more-warning-options-to-fgcc-compatible.patch +++ b/0007-add-more-warning-options-to-fgcc-compatible.patch @@ -5,13 +5,13 @@ Subject: [PATCH] add more warning options to -fgcc-compatible --- clang/lib/Driver/ToolChains/Clang.cpp | 20 ++++++++++++++++++++ - 1 file changed, 20 insertions(+) + 1 file changed, 25 insertions(+) diff --git a/clang/lib/Driver/ToolChains/Clang.cpp b/clang/lib/Driver/ToolChains/Clang.cpp index 793af55a1e5f..f0da323d8adb 100644 --- a/clang/lib/Driver/ToolChains/Clang.cpp +++ b/clang/lib/Driver/ToolChains/Clang.cpp -@@ -4683,11 +4683,37 @@ void Clang::ConstructJob(Compilation &C, const JobAction &JA, +@@ -4683,11 +4683,42 @@ void Clang::ConstructJob(Compilation &C, const JobAction &JA, #ifdef BUILD_FOR_OPENEULER if (Args.hasFlag(options::OPT_fgcc_compatible, options::OPT_fno_gcc_compatible, false)) { @@ -41,11 +41,16 @@ index 793af55a1e5f..f0da323d8adb 100644 + CmdArgs.push_back("-Wno-error=implicit-int"); + CmdArgs.push_back("-Wno-error=enum-constexpr-conversion"); + CmdArgs.push_back("-Wno-error=return-type"); ++ CmdArgs.push_back("-Wno-error=reserved-user-defined-literal"); + } + //other warnings + CmdArgs.push_back("-Wno-error=cast-align"); + CmdArgs.push_back("-Wno-error=enum-conversion"); + CmdArgs.push_back("-Wno-error=switch"); ++ CmdArgs.push_back("-Wno-error=cast-qual"); ++ CmdArgs.push_back("-Wno-error=varargs"); ++ CmdArgs.push_back("-Wno-error=unused-value"); ++ CmdArgs.push_back("-Wno-error=format-nonliteral"); } #endif diff --git a/clang.spec b/clang.spec index 0152e88c442289b227075a45f5424afd9ebe551b..3ed3bff1f6e134e97e3789a3a19a7d3d666492ee 100644 --- a/clang.spec +++ b/clang.spec @@ -36,7 +36,7 @@ Name: %{pkg_name} Version: %{clang_version} -Release: 12 +Release: 13 Summary: A C language family front-end for LLVM License: NCSA @@ -382,6 +382,9 @@ LD_LIBRARY_PATH=%{buildroot}/%{install_libdir} %{__ninja} check-all -C ./_build %{install_bindir}/git-clang-format %changelog +* Sat Apr 13 2024 liyunfei -17.0.6-13 +- Add more warning options to BUILD_FOR_OPENEULER gcc compatible part 3. + * Tue Apr 09 2024 zhanglimin - 17.0.6-12 - Improve the support for compiler-rt and fix some bugs on LoongArch.