From 8cdba50ea1e124270a1341366aa83e73ad408bc9 Mon Sep 17 00:00:00 2001 From: Dave Collins Date: Thu, 18 Sep 2014 13:22:57 -0500 Subject: Rework build to support more liberal unix variants. Rather than having the build setup such that it will only work on the specifically defined operating systems, this commit modifies it to use more liberal !windows,!plan9 build tag for the unix specific bits. This means bolt will compile on more Operating Systems such as OpenBSD, FreeBSD, and NetBSD. See boltdb/bolt#257 for discussion. --- boltsync_unix.go | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 boltsync_unix.go (limited to 'boltsync_unix.go') diff --git a/boltsync_unix.go b/boltsync_unix.go new file mode 100644 index 0000000..3c54dd5 --- /dev/null +++ b/boltsync_unix.go @@ -0,0 +1,14 @@ +// +build !windows,!plan9,!linux + +package bolt + +import ( + "os" +) + +var odirect int + +// fdatasync flushes written data to a file descriptor. +func fdatasync(f *os.File) error { + return f.Sync() +} -- cgit v1.2.3