mount: keep the xattr flag constants off freebsd

x/sys/unix has no XATTR_CREATE or XATTR_REPLACE there, and weedfs_xattr.go
is already tagged away from freebsd for that reason. Putting the constants
in a !windows file dragged them back in and broke the freebsd build.
This commit is contained in:
Chris Lu
2026-08-03 09:11:31 -07:00
parent 74b323cc3b
commit f409c2588f
2 changed files with 11 additions and 8 deletions
+1 -8
View File
@@ -2,18 +2,11 @@
package mount
import (
"syscall"
sys "golang.org/x/sys/unix"
)
import "syscall"
const (
f_RDLCK = syscall.F_RDLCK
f_WRLCK = syscall.F_WRLCK
f_UNLCK = syscall.F_UNLCK
o_ACCMODE = syscall.O_ACCMODE
xattr_CREATE = sys.XATTR_CREATE
xattr_REPLACE = sys.XATTR_REPLACE
)
+10
View File
@@ -0,0 +1,10 @@
//go:build !windows && !freebsd
package mount
import sys "golang.org/x/sys/unix"
const (
xattr_CREATE = sys.XATTR_CREATE
xattr_REPLACE = sys.XATTR_REPLACE
)