From 9c4c5561838dd19e128da7de426e10a33267b7b4 Mon Sep 17 00:00:00 2001 From: David Abdurachmanov Date: Sat, 23 Jul 2022 18:45:30 +0200 Subject: [PATCH] Enable riscv64 (bootstrap) Signed-off-by: David Abdurachmanov --- golang.spec | 22 ++++++++++++++++------ 1 file changed, 16 insertions(+), 6 deletions(-) diff --git a/golang.spec b/golang.spec index 5291aa0..f735f2c 100644 --- a/golang.spec +++ b/golang.spec @@ -1,7 +1,11 @@ +%ifnarch riscv64 %bcond_with bootstrap +%else +%bcond_without bootstrap +%endif # temporalily ignore test failures # due to https://github.com/golang/go/issues/39466 -%ifarch aarch64 +%ifarch aarch64 riscv64 %bcond_without ignore_tests %else %bcond_with ignore_tests @@ -39,14 +43,14 @@ # Golang build options. # Build golang using external/internal(close to cgo disabled) linking. -%ifarch %{ix86} x86_64 ppc64le %{arm} aarch64 s390x +%ifarch %{ix86} x86_64 ppc64le %{arm} aarch64 s390x riscv64 %global external_linker 1 %else %global external_linker 0 %endif # Build golang with cgo enabled/disabled(later equals more or less to internal linking). -%ifarch %{ix86} x86_64 ppc64le %{arm} aarch64 s390x +%ifarch %{ix86} x86_64 ppc64le %{arm} aarch64 s390x riscv64 %global cgo_enabled 1 %else %global cgo_enabled 0 @@ -67,7 +71,7 @@ %endif # Build golang shared objects for stdlib -%ifarch %{ix86} x86_64 ppc64le %{arm} aarch64 +%ifarch %{ix86} x86_64 ppc64le %{arm} aarch64 riscv64 %global shared 1 %else %global shared 0 @@ -104,6 +108,9 @@ %ifarch s390x %global gohostarch s390x %endif +%ifarch riscv64 +%global gohostarch riscv64 +%endif # Comment out go_prerelease and go_patch as needed %global go_api 1.18 @@ -118,7 +125,7 @@ Name: golang Version: %{go_version} -Release: %{baserelease}%{?dist} +Release: %{baserelease}.0.riscv64%{?dist} Summary: The Go Programming Language # source tree includes several copies of Mark.Twain-Tom.Sawyer.txt under Public Domain License: BSD and Public Domain @@ -471,7 +478,7 @@ export CGO_ENABLED=0 #endif # make sure to not timeout -export GO_TEST_TIMEOUT_SCALE=2 +export GO_TEST_TIMEOUT_SCALE=20 %if %{fail_on_tests} ./run.bash --no-rebuild -v -v -v -k @@ -541,6 +548,9 @@ fi %endif %changelog +* Sat Jul 23 2022 David Abdurachmanov - 1.18.4-1.0.riscv64 +- Enable riscv64 (bootstrap) + * Wed Jul 13 2022 Alejandro Sáez - 1.18.4-1 - Update to 1.18.4