23 lines
542 B
Go
23 lines
542 B
Go
//go:build !linux && !windows
|
|
|
|
package main
|
|
|
|
import (
|
|
"fmt"
|
|
"runtime"
|
|
)
|
|
|
|
// Stubs so clonetool still builds (and runs for regular-file syncs) on
|
|
// platforms without raw block-device support wired up (e.g. macOS for local
|
|
// development). Block-device paths error out clearly.
|
|
|
|
func isRawDevice(string) bool { return false }
|
|
|
|
func blockDeviceSize(string) (int64, error) {
|
|
return 0, fmt.Errorf("block devices are not supported on %s", runtime.GOOS)
|
|
}
|
|
|
|
func deviceAlignment(string) int64 { return 1 }
|
|
|
|
func canElevate() bool { return true }
|