diff --git a/0002-Add-triples-for-X86_64-AArch64-openEuler-gcc.patch b/0002-Add-triples-for-X86_64-AArch64-openEuler-gcc.patch new file mode 100644 index 0000000000000000000000000000000000000000..b739bdc734a17291ba834f54ec7d0b164f380616 --- /dev/null +++ b/0002-Add-triples-for-X86_64-AArch64-openEuler-gcc.patch @@ -0,0 +1,35 @@ +From 8784fb0b365318302e2ef08309618cb9cffae0df Mon Sep 17 00:00:00 2001 +From: liyunfei +Date: Wed, 26 Jul 2023 14:37:00 +0800 +Subject: [PATCH] Add triples for X86_64/AArch64 openEuler gcc + +--- + clang/lib/Driver/ToolChains/Gnu.cpp | 5 +++-- + 1 file changed, 3 insertions(+), 2 deletions(-) + +diff --git a/clang/lib/Driver/ToolChains/Gnu.cpp b/lib/Driver/ToolChains/Gnu.cpp +index 1d8a3cd..1089113 100644 +--- a/clang/lib/Driver/ToolChains/Gnu.cpp ++++ b/clang/lib/Driver/ToolChains/Gnu.cpp +@@ -2075,7 +2075,7 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes( + static const char *const AArch64LibDirs[] = {"/lib64", "/lib"}; + static const char *const AArch64Triples[] = { + "aarch64-none-linux-gnu", "aarch64-linux-gnu", "aarch64-redhat-linux", +- "aarch64-suse-linux", "aarch64-linux-android"}; ++ "aarch64-suse-linux", "aarch64-linux-android", "aarch64-openEuler-linux"}; + static const char *const AArch64beLibDirs[] = {"/lib"}; + static const char *const AArch64beTriples[] = {"aarch64_be-none-linux-gnu", + "aarch64_be-linux-gnu"}; +@@ -2103,7 +2103,8 @@ void Generic_GCC::GCCInstallationDetector::AddDefaultGCCPrefixes( + "x86_64-redhat-linux", "x86_64-suse-linux", + "x86_64-manbo-linux-gnu", "x86_64-linux-gnu", + "x86_64-slackware-linux", "x86_64-unknown-linux", +- "x86_64-amazon-linux", "x86_64-linux-android"}; ++ "x86_64-amazon-linux", "x86_64-linux-android", ++ "x86_64-openEuler-linux"}; + static const char *const X32LibDirs[] = {"/libx32"}; + static const char *const X86LibDirs[] = {"/lib32", "/lib"}; + static const char *const X86Triples[] = { +-- +2.28.0.windows.1 + diff --git a/clang.spec b/clang.spec index 44ea45e94e197dc3410584f2d3bc8a99193889dc..3cf1f893055ceb6bcd9dc7a5f39180fb732a1ad7 100644 --- a/clang.spec +++ b/clang.spec @@ -34,7 +34,7 @@ Name: %{pkg_name} Version: %{clang_version} -Release: 4 +Release: 5 Summary: A C language family front-end for LLVM License: NCSA @@ -44,6 +44,7 @@ Source1: https://github.com/llvm/llvm-project/releases/download/llvmorg-%{clang_ Patch1: 0001-fedora-PATCH-clang-Reorganize-gtest-integration.patch Patch2: 0003-fedora-PATCH-clang-Don-t-install-static-libraries.patch +Patch3: 0002-Add-triples-for-X86_64-AArch64-openEuler-gcc.patch Patch201: support-ignored_and_replaced_opts.patch Patch202: support-print-c-function-prototype.patch @@ -324,6 +325,9 @@ LD_LIBRARY_PATH=%{buildroot}/%{install_libdir} %{__ninja} check-all -C ./_build %{install_bindir}/git-clang-format %changelog +* Wed Jul 26 2023 liyunfei - 12.0.1-5 +- Add triples for X86_64/AArch64 openEuler gcc + * Thu Jul 6 2023 cf-zhao -12.0.1-4 - Make this spec file support both system-version and multi-version.