OSDN Git Service

should include sys/types.h for mode_t
[lha/olha.git] / test.sh
diff --git a/test.sh b/test.sh
index 110de53..924f88c 100644 (file)
--- a/test.sh
+++ b/test.sh
@@ -1,8 +1,13 @@
 #!/bin/sh
 
 set -ex
-VALGRIND="valgrind -q"
-#VALGRIND=
+
+VALGRIND=
+if [ "$1" = -v ]; then
+  if which valgrind 2>/dev/null; then
+    VALGRIND="valgrind -q"
+  fi
+fi
 
 if [ -f olha.exe ]; then
   cp olha.exe olha2