Mercurial > hg > truffle
diff test/runtime/jsig/Test8017498.sh @ 11967:f9ee986a9fea
8021296: [TESTBUG] Test8017498.sh fails to find "gcc" and fails to compile on some Linux releases
Summary: Added checking for gcc and simplified the sig_handler() in the test case
Reviewed-by: dcubed, coleenp, minqi, dlong
author | ccheung |
---|---|
date | Tue, 30 Jul 2013 14:14:25 -0700 |
parents | 72727c4b6dec |
children | e567d5afd4dd |
line wrap: on
line diff
--- a/test/runtime/jsig/Test8017498.sh Fri Jul 26 15:24:32 2013 +0000 +++ b/test/runtime/jsig/Test8017498.sh Tue Jul 30 14:14:25 2013 -0700 @@ -27,6 +27,7 @@ ## @test Test8017498.sh ## @bug 8017498 ## @bug 8020791 +## @bug 8021296 ## @summary sigaction(sig) results in process hang/timed-out if sig is much greater than SIGRTMAX ## @run shell/timeout=30 Test8017498.sh ## @@ -45,6 +46,11 @@ case "$OS" in Linux) echo "Testing on Linux" + gcc_cmd=`which gcc` + if [ "x$gcc_cmd" == "x" ]; then + echo "WARNING: gcc not found. Cannot execute test." 2>&1 + exit 0; + fi if [ "$VM_BITS" = "64" ] then MY_LD_PRELOAD=${TESTJAVA}${FS}jre${FS}lib${FS}amd64${FS}libjsig.so @@ -64,15 +70,11 @@ cp ${TESTSRC}${FS}*.java ${THIS_DIR} ${TESTJAVA}${FS}bin${FS}javac *.java -gcc -DLINUX -fPIC -shared \ +$gcc_cmd -DLINUX -fPIC -shared \ -o ${TESTSRC}${FS}libTestJNI.so \ -I${TESTJAVA}${FS}include \ -I${TESTJAVA}${FS}include${FS}linux \ ${TESTSRC}${FS}TestJNI.c -if [ $? != 0 ] -then - echo "WARNING: the gcc command failed." 2>&1 -fi # run the java test in the background cmd="LD_PRELOAD=$MY_LD_PRELOAD \