summaryrefslogtreecommitdiff
path: root/scripts/install.sh
diff options
context:
space:
mode:
authorWaldemar Brodkorb <wbx@openadk.org>2011-01-01 20:58:20 +0100
committerWaldemar Brodkorb <wbx@openadk.org>2011-01-01 20:58:20 +0100
commit9d40adece525b0989001e3a8f486e76b3996f8e5 (patch)
treef00262ab0b3661f591aa079d06183572c30a8765 /scripts/install.sh
parent33c84781ec8c0225472bd1bf00184efcdff3c20b (diff)
fix recognition of BSD stat. now busybox stat works, too.
Diffstat (limited to 'scripts/install.sh')
-rwxr-xr-xscripts/install.sh6
1 files changed, 3 insertions, 3 deletions
diff --git a/scripts/install.sh b/scripts/install.sh
index 8eb6ee062..7b3b5bc4d 100755
--- a/scripts/install.sh
+++ b/scripts/install.sh
@@ -201,10 +201,10 @@ if (( cyls < (cfgfs + 2) )); then
exit 1
fi
-if stat --help >/dev/null 2>&1; then
- statcmd='stat -c %s' # GNU stat
-else
+if stat -qs .>/dev/null 2>&1; then
statcmd='stat -f %z' # BSD stat (or so we assume)
+else
+ statcmd='stat -c %s' # GNU stat
fi
if ! T=$(mktemp -d /tmp/openadk.XXXXXXXXXX); then