From 18531e3d6f3b22cdae7d527f1eff81d65ceecfba Mon Sep 17 00:00:00 2001
From: greatroar <@>
Date: Sun, 24 May 2020 19:30:20 +0200
Subject: [PATCH] Portability fixes to internal/restic

syscall.Mknod is not available on AIX.
---
 cmd/restic/integration_fuse_test.go | 5 +----
 internal/restic/node_unix.go        | 6 ++++--
 internal/restic/node_xattr.go       | 5 +----
 3 files changed, 6 insertions(+), 10 deletions(-)

diff --git a/cmd/restic/integration_fuse_test.go b/cmd/restic/integration_fuse_test.go
index 17e73abc6..7da85881e 100644
--- a/cmd/restic/integration_fuse_test.go
+++ b/cmd/restic/integration_fuse_test.go
@@ -1,7 +1,4 @@
-// +build !netbsd
-// +build !openbsd
-// +build !solaris
-// +build !windows
+// +build darwin freebsd linux
 
 package main
 
diff --git a/internal/restic/node_unix.go b/internal/restic/node_unix.go
index f220725a9..e81b77076 100644
--- a/internal/restic/node_unix.go
+++ b/internal/restic/node_unix.go
@@ -1,13 +1,15 @@
-// +build dragonfly linux netbsd openbsd freebsd solaris darwin
+// +build !windows
 
 package restic
 
 import (
 	"os"
 	"syscall"
+
+	"golang.org/x/sys/unix"
 )
 
-var mknod = syscall.Mknod
+var mknod = unix.Mknod
 var lchown = os.Lchown
 
 type statT syscall.Stat_t
diff --git a/internal/restic/node_xattr.go b/internal/restic/node_xattr.go
index c95257560..f66ddab84 100644
--- a/internal/restic/node_xattr.go
+++ b/internal/restic/node_xattr.go
@@ -1,7 +1,4 @@
-// +build !netbsd
-// +build !openbsd
-// +build !solaris
-// +build !windows
+// +build darwin freebsd linux
 
 package restic