#!/bin/bash # # wrapper for testing molecuilder . ../../atlocal trap 'echo "Killing process group $$"; pkill --signal 9 -P $$' SIGTERM SIGINT #PGID=$(ps -o pgid= $PID | grep -o [0-9]*) #trap 'kill -- -"$PGID"' SIGINT SIGTERM SCLIBDIR="@abs_top_srcdir@/ThirdParty/mpqc_open/lib" export SCLIBDIR if test -e ${AUTOTEST_PATH}/molecuilder_poolworker; then ${AUTOTEST_PATH}/molecuilder_poolworker $@ & else echo "Could not find molecuilder_poolworker." exit 127 fi # we need the wait here (and poolworker running in the background) as otherwise # the above trap will not get activated. wait $! status=$? exit $status