From 579f3b689d0f0e479125f6aa64957edf18ea59be Mon Sep 17 00:00:00 2001 From: liyunfei Date: Fri, 15 Dec 2023 11:12:03 +0800 Subject: [PATCH] Add triples for X86_64/AArch64 openEuler gcc --- ...les-for-X86_64-AArch64-openEuler-gcc.patch | 33 +++++++++++++++++++ clang.spec | 6 +++- 2 files changed, 38 insertions(+), 1 deletion(-) create mode 100644 0001-Add-triples-for-X86_64-AArch64-openEuler-gcc.patch diff --git a/0001-Add-triples-for-X86_64-AArch64-openEuler-gcc.patch b/0001-Add-triples-for-X86_64-AArch64-openEuler-gcc.patch new file mode 100644 index 0000000..a2066f0 --- /dev/null +++ b/0001-Add-triples-for-X86_64-AArch64-openEuler-gcc.patch @@ -0,0 +1,33 @@ +From a833e7fa829764f8e3bf6b059c9e91080ca55253 Mon Sep 17 00:00:00 2001 +From: liyunfei +Date: Mon, 24 Jul 2023 19:16:45 +0800 +Subject: [PATCH] Add triples for X86_64/AArch64 openEuler gcc + +--- + clang/lib/Driver/ToolChains/Gnu.cpp | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/clang/lib/Driver/ToolChains/Gnu.cpp b/clang/lib/Driver/ToolChains/Gnu.cpp +index 665cdc3132fb..fc56935e7513 100644 +--- a/clang/lib/Driver/ToolChains/Gnu.cpp ++++ b/clang/lib/Driver/ToolChains/Gnu.cpp +@@ -2178,7 +2178,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-suse-linux", "aarch64-openEuler-linux"}; + static const char *const AArch64beLibDirs[] = {"/lib"}; + static const char *const AArch64beTriples[] = {"aarch64_be-none-linux-gnu", + "aarch64_be-linux-gnu"}; +@@ -2208,7 +2208,7 @@ 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-amazon-linux", "x86_64-openEuler-linux"}; + static const char *const X32Triples[] = {"x86_64-linux-gnux32", + "x86_64-pc-linux-gnux32"}; + static const char *const X32LibDirs[] = {"/libx32", "/lib"}; +-- +2.28.0.windows.1 diff --git a/clang.spec b/clang.spec index 7238df5..fcd3f0b 100644 --- a/clang.spec +++ b/clang.spec @@ -36,7 +36,7 @@ Name: %{pkg_name} Version: %{clang_version} -Release: 1 +Release: 2 Summary: A C language family front-end for LLVM License: NCSA @@ -45,6 +45,7 @@ Source0: https://github.com/llvm/llvm-project/releases/download/llvmorg-%{clang_ Source1: https://github.com/llvm/llvm-project/releases/download/llvmorg-%{clang_version}/%{clang_tools_srcdir}.tar.xz Patch0: fedora-PATCH-clang-Don-t-install-static-libraries.patch +Patch1: 0001-Add-triples-for-X86_64-AArch64-openEuler-gcc.patch # Patches for clang-tools-extra # See https://reviews.llvm.org/D120301 @@ -370,6 +371,9 @@ LD_LIBRARY_PATH=%{buildroot}/%{install_libdir} %{__ninja} check-all -C ./_build %{install_bindir}/git-clang-format %changelog +* Fri Dec 15 2023 liyunfei -17.0.6-2 +- Add triples for X86_64/AArch64 openEuler gcc + * Thu Nov 30 2023 zhoujing -17.0.6-1 - Update to 17.0.6