aboutsummaryrefslogtreecommitdiffstats
path: root/tools/libfsimage/check-libext2fs
diff options
context:
space:
mode:
authorKeir Fraser <keir.fraser@citrix.com>2008-03-26 14:40:54 +0000
committerKeir Fraser <keir.fraser@citrix.com>2008-03-26 14:40:54 +0000
commitbf69b5d7858f83902b5fd61546400334a40c016c (patch)
tree9f227a9eaaf38a9cf228c9fae5ebe71115b56048 /tools/libfsimage/check-libext2fs
parent88b932f50f86522e70a978c1e081b99aee2f8374 (diff)
downloadxen-bf69b5d7858f83902b5fd61546400334a40c016c.tar.gz
xen-bf69b5d7858f83902b5fd61546400334a40c016c.tar.bz2
xen-bf69b5d7858f83902b5fd61546400334a40c016c.zip
libfsimage: portability fixes for NetBSD
Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
Diffstat (limited to 'tools/libfsimage/check-libext2fs')
-rwxr-xr-xtools/libfsimage/check-libext2fs6
1 files changed, 4 insertions, 2 deletions
diff --git a/tools/libfsimage/check-libext2fs b/tools/libfsimage/check-libext2fs
index e6a8d186fc..b6fa7fbacd 100755
--- a/tools/libfsimage/check-libext2fs
+++ b/tools/libfsimage/check-libext2fs
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
cat >ext2-test.c <<EOF
#include <ext2fs/ext2fs.h>
@@ -9,7 +9,9 @@ int main()
}
EOF
-${CC:-gcc} -o ext2-test ext2-test.c -lext2fs >/dev/null 2>&1
+if test -z ${CC}; then CC="gcc"; fi
+${CC} -o ext2-test ext2-test.c -lext2fs >/dev/null 2>&1
+
if [ $? = 0 ]; then
echo ext2fs-lib
else