From 8daa0f82134c5e48b0aedcb258c8a0ca39127f99 Mon Sep 17 00:00:00 2001 From: Guoguo Date: Thu, 9 Nov 2023 06:34:22 +0000 Subject: [PATCH] add riscv64 for fpc, ghc, gnat, java and nodejs macros add optflags for riscv64 Signed-off-by: Guoguo --- macros | 2 +- macros.fpc-srpm | 2 +- macros.ghc-srpm | 2 +- macros.gnat-srpm | 2 +- macros.java-srpm | 2 +- macros.nodejs-srpm | 2 +- rpmrc | 2 ++ system-rpm-config.spec | 6 +++++- 8 files changed, 13 insertions(+), 7 deletions(-) diff --git a/macros b/macros index eb8dfa8..1c81dbb 100644 --- a/macros +++ b/macros @@ -369,7 +369,7 @@ print(result) # way we can detect installing an unusable .o/.a file. This is on the TODO # list for F34. %_gcc_lto_cflags -flto=auto -ffat-lto-objects -%_clang_lto_cflags -flto +%_clang_lto_cflags %[ "%{_target_cpu}" == "riscv64" ? "" : "-flto" ] %_lto_cflags %{expand:%%{_%{toolchain}_lto_cflags}} # Some linkers default to a build-id algoritim that is not supported by rpmbuild, diff --git a/macros.fpc-srpm b/macros.fpc-srpm index b87092b..7cc085a 100644 --- a/macros.fpc-srpm +++ b/macros.fpc-srpm @@ -1 +1 @@ -%fpc_arches x86_64 aarch64 +%fpc_arches x86_64 aarch64 riscv64 diff --git a/macros.ghc-srpm b/macros.ghc-srpm index 319e622..b781664 100644 --- a/macros.ghc-srpm +++ b/macros.ghc-srpm @@ -1,6 +1,6 @@ # ghc_arches is not used in current packages but still here for back compat # former archs: alpha ppc sparcv9 armv5tel -%ghc_arches x86_64 aarch64 +%ghc_arches x86_64 aarch64 riscv64 # deprecated - kept for ghc.spec back compatibility %ghc_devel_prof prof diff --git a/macros.gnat-srpm b/macros.gnat-srpm index bba90c1..7851e5c 100644 --- a/macros.gnat-srpm +++ b/macros.gnat-srpm @@ -1,2 +1,2 @@ -%GPRbuild_arches aarch64 x86_64 +%GPRbuild_arches aarch64 x86_64 riscv64 %GNAT_arches %{GPRbuild_arches} diff --git a/macros.java-srpm b/macros.java-srpm index f31d492..125efd5 100644 --- a/macros.java-srpm +++ b/macros.java-srpm @@ -1,2 +1,2 @@ # Arches that OpenJDK and dependent packages run on -%java_arches aarch64 x86_64 loongarch64 +%java_arches aarch64 x86_64 loongarch64 riscv64 diff --git a/macros.nodejs-srpm b/macros.nodejs-srpm index 0a2e89b..c212943 100644 --- a/macros.nodejs-srpm +++ b/macros.nodejs-srpm @@ -2,5 +2,5 @@ # Enabling Node.js on other arches requires porting the V8 JavaScript JIT to # those arches. -%nodejs_arches x86_64 aarch64 loongarch64 +%nodejs_arches x86_64 aarch64 loongarch64 riscv64 diff --git a/rpmrc b/rpmrc index c504d87..d9dd759 100644 --- a/rpmrc +++ b/rpmrc @@ -5,3 +5,5 @@ optflags: x86_64 %{__global_compiler_flags} -m64 %{__cflags_arch_x86_64} -mtune= optflags: aarch64 %{__global_compiler_flags} -mbranch-protection=standard -fasynchronous-unwind-tables %[ "%{toolchain}" == "gcc" ? "-fstack-clash-protection" : "" ] optflags: loongarch64 %{__global_compiler_flags} -fasynchronous-unwind-tables %[ "%{toolchain}" == "gcc" ? "-fstack-clash-protection" : "" ] + +optflags: riscv64 %{__global_compiler_flags} -fasynchronous-unwind-tables %[ "%{toolchain}" == "gcc" ? "-fstack-clash-protection" : "" ] \ No newline at end of file diff --git a/system-rpm-config.spec b/system-rpm-config.spec index ea80375..2c52c3c 100644 --- a/system-rpm-config.spec +++ b/system-rpm-config.spec @@ -1,4 +1,4 @@ -%define anolis_release 34 +%define anolis_release 35 Summary: Anolis OS specific rpm configuration files Name: system-rpm-config @@ -211,6 +211,10 @@ install -p -m 644 -t %{buildroot}%{_rpmluadir}/anolis/srpm forge.lua %license MulanPSL %changelog +* Thu Nov 9 2023 Guoguo - 1:23-35 +- add riscv64 for fpc, ghc, gnat, java and nodejs macros +- add optflags for riscv64 + * Sun Oct 8 2023 Wenlong Zhang - 1:23-34 - add loongarch64 for nodejs and java macros - add optflags for loongarch64 -- Gitee