sevlyar / go-daemon

A library for writing system daemons in golang.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

FTBS on riscv64

Civil opened this issue · comments

syscall_dup.go:11:9: undefined: syscall.Dup2

Problem is the same as with arm64 - new platforms do not have syscall.Dup2, but have syscall.Dup3 instead.

Proper solution would be to get a list of all platforms that have Dup2 syscall and whitelist them for old one and use new one for all other platforms (as new platforms will likely implement Dup3 syscall and not Dup2).

Or at least to:

  1. Rename syscall_dup_arm64.go to not include arch name
  2. Build it on:
// +build linux
// +build arm64 riscv64
  1. Do not build old file on riscv64 (simple header modification).