notmuch/test/test-lib-FREEBSD.sh
Mikhail 9b7dbed58e tests: add compatibility layer
Make test-lib-common.sh load test-lib-<$PLATFORM>.sh to create
additional shim for platform specifics.

Use test-lib-FREEBSD.sh to call GNU utilities instead of native ones.

- amended by db following Tomi's suggestions
2017-03-25 07:56:52 -03:00

9 lines
270 B
Bash

# If present, use GNU Coreutils instead of a native BSD utils
if command -v gdate >/dev/null
then
date () { gdate "$@"; }
base64 () { gbase64 "$@"; }
wc () { gwc "$@"; }
sed () { gsed "$@"; }
sha256sum () { gsha256sum "$@"; }
fi