From: Alexis Laferrière Date: Wed, 1 Oct 2014 16:09:09 +0000 (-0400) Subject: tests.sh: support absolute path to outdir X-Git-Tag: v0.6.10~39^2~5 X-Git-Url: http://nitlanguage.org?ds=sidebyside tests.sh: support absolute path to outdir Signed-off-by: Alexis Laferrière --- diff --git a/tests/tests.sh b/tests/tests.sh index c28de15..4d8ad78 100755 --- a/tests/tests.sh +++ b/tests/tests.sh @@ -439,10 +439,10 @@ for ii in "$@"; do fi if [ -n "$isinterpret" ]; then - cat > "./$ff.bin" < "$ff.bin" < "$ff.cmp.err" > "$ff.compile.log" ERR=0 @@ -467,7 +467,7 @@ END fi fi if [ "$engine" = "emscripten" ]; then - echo > "./$ff.bin" "nodejs $ffout \"\$@\"" + echo > "$ff.bin" "nodejs $ffout \"\$@\"" chmod +x "$ff.bin" if grep "Fatal Error: more than one primitive class" "$ff.compile.log" > /dev/null; then echo " [skip] do no not imports kernel" @@ -484,7 +484,7 @@ END echo -n "nocc " > "$ff.res" process_result $bf $bf $pack - elif [ -x "./$ff.bin" ]; then + elif [ -x "$ff.bin" ]; then if skip_exec "$bf"; then # No exec > "$ff.res" @@ -496,7 +496,7 @@ END args="" if [ "x$verbose" = "xtrue" ]; then echo "" - echo "NIT_NO_STACK=1 ./$ff.bin" $args + echo "NIT_NO_STACK=1 $ff.bin" $args fi NIT_NO_STACK=1 LD_LIBRARY_PATH=$JNI_LIB_PATH \ /usr/bin/time --quiet -f%U -a -o "$ff.time.out" $TIMEOUT "./$ff.bin" $args < "$inputs" > "$ff.res" 2>"$ff.err" @@ -539,11 +539,11 @@ END rm -rf "$fff.res" "$fff.err" "$fff.write" 2> /dev/null if [ "x$verbose" = "xtrue" ]; then echo "" - echo "NIT_NO_STACK=1 ./$ff.bin" $args + echo "NIT_NO_STACK=1 $ff.bin" $args fi echo -n "==> $name " - echo "./$ff.bin $args" > "./$fff.bin" - chmod +x "./$fff.bin" + echo "$ff.bin $args" > "$fff.bin" + chmod +x "$fff.bin" WRITE="$fff.write" /usr/bin/time --quiet -f%U -o "$fff.time.out" sh -c "NIT_NO_STACK=1 $TIMEOUT ./$fff.bin < $ffinputs > $fff.res 2>$fff.err" if [ "x$verbose" = "xtrue" ]; then cat "$fff.res" @@ -561,7 +561,7 @@ END process_result $bff " $name" $pack done < $fargs fi - elif [ -f "./$ff.bin" ]; then + elif [ -f "$ff.bin" ]; then #Not executable (platform?)" > "$ff.res" process_result $bf "$bf" $pack