Use dup3 for riscv64
Signed-off-by: David Abdurachmanov <davidlt@rivosinc.com>
This commit is contained in:
parent
0ff66d161b
commit
d18d64acbc
@ -31,7 +31,7 @@ section below on why.}
|
||||
%global gosupfiles glide.lock glide.yaml
|
||||
|
||||
Name: %{goname}
|
||||
Release: 6%{?dist}
|
||||
Release: 6.0.riscv64%{?dist}
|
||||
Summary: Go library for catching and handling panics in Go applications
|
||||
|
||||
License: MIT
|
||||
@ -44,6 +44,9 @@ Source2: glide.lock
|
||||
# https://github.com/bugsnag/panicwrap/issues/20
|
||||
Patch0: 0001-Prevent-the-build-of-dup2.go-on-Linux-aarch64.patch
|
||||
|
||||
# riscv64 is identical to arm64
|
||||
Patch1: linux-use-dup3-riscv64.patch
|
||||
|
||||
%description
|
||||
%{common_description}
|
||||
|
||||
@ -52,6 +55,7 @@ Patch0: 0001-Prevent-the-build-of-dup2.go-on-Linux-aarch64.patch
|
||||
%prep
|
||||
%goprep
|
||||
%patch0 -p1
|
||||
%patch1 -p1
|
||||
cp %{S:1} %{S:2} .
|
||||
|
||||
%install
|
||||
@ -65,6 +69,9 @@ cp %{S:1} %{S:2} .
|
||||
%gopkgfiles
|
||||
|
||||
%changelog
|
||||
* Fri Jul 07 2023 David Abdurachmanov <davidlt@rivosinc.com> - 1.3.2-6.0.riscv64
|
||||
- Use dup3 for riscv64
|
||||
|
||||
* Thu Jan 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 1.3.2-6
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
|
||||
|
||||
|
21
linux-use-dup3-riscv64.patch
Normal file
21
linux-use-dup3-riscv64.patch
Normal file
@ -0,0 +1,21 @@
|
||||
diff --git a/dup2.go b/dup2.go
|
||||
index 279435f..52a02b4 100644
|
||||
--- a/dup2.go
|
||||
+++ b/dup2.go
|
||||
@@ -1,5 +1,5 @@
|
||||
// +build !windows
|
||||
-// +build linux,!arm64
|
||||
+// +build linux,!arm64 linux,!riscv64
|
||||
|
||||
package panicwrap
|
||||
|
||||
diff --git a/dup3.go b/dup3.go
|
||||
index 9417bc7..ddf1ac5 100644
|
||||
--- a/dup3.go
|
||||
+++ b/dup3.go
|
||||
@@ -1,4 +1,4 @@
|
||||
-//+build linux,arm64
|
||||
+//+build linux,arm64 linux,riscv64
|
||||
|
||||
package panicwrap
|
||||
|
Loading…
Reference in New Issue
Block a user