mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-07-23 11:15:13 +03:00
42 lines
1 KiB
Diff
42 lines
1 KiB
Diff
From 8360ec2b75d713267aed4cc2863a2b430105fb48 Mon Sep 17 00:00:00 2001
|
|
From: Carlo Landmeter <clandmeter@alpinelinux.org>
|
|
Date: Sun, 20 Jun 2021 21:07:44 +0000
|
|
Subject: [PATCH] logging: add support for riscv64
|
|
|
|
---
|
|
logging/logging_other.go | 1 +
|
|
logging/logging_riscv64.go | 12 ++++++++++++
|
|
2 files changed, 13 insertions(+)
|
|
create mode 100644 logging/logging_riscv64.go
|
|
|
|
diff --git a/logging/logging_other.go b/logging/logging_other.go
|
|
index e910821..d4234ce 100644
|
|
--- a/logging/logging_other.go
|
|
+++ b/logging/logging_other.go
|
|
@@ -1,4 +1,5 @@
|
|
// +build linux,!arm64 openbsd,!arm64 freebsd darwin,!arm64
|
|
+// +build linux,!riscv64 openbsd,!riscv64 freebsd darwin,!riscv64
|
|
|
|
package logging
|
|
|
|
diff --git a/logging/logging_riscv64.go b/logging/logging_riscv64.go
|
|
new file mode 100644
|
|
index 0000000..5b269b1
|
|
--- /dev/null
|
|
+++ b/logging/logging_riscv64.go
|
|
@@ -0,0 +1,12 @@
|
|
+// +build !freebsd,riscv64
|
|
+
|
|
+package logging
|
|
+
|
|
+import (
|
|
+ "os"
|
|
+ "syscall"
|
|
+)
|
|
+
|
|
+func stderrToLogfile(logfile *os.File) {
|
|
+ syscall.Dup3(int(logfile.Fd()), 2, 0)
|
|
+}
|
|
--
|
|
2.32.0
|
|
|