diff --git a/libisoburn/trunk/releng/README b/libisoburn/trunk/releng/README index d1b0547a..65192e7f 100644 --- a/libisoburn/trunk/releng/README +++ b/libisoburn/trunk/releng/README @@ -248,11 +248,18 @@ to the general options of the test suite: Default 1. Setable to 0 by option -k. SPECIFIC_HELP 0=normal operation, 1=print help text of script and exit 0 - Default 0. Setable to 1 by option -h + Default 0. Setable to 1 by option -h. + + RELENG_STANDALONE 0=standalone, 1=supervised by run_all_auto script. + + RELENG_PARENT Name of the parent process. The code piece inc/releng_getopts.inc defines the following functions for use by the single tests: + standalone_or_supervised Initialize the running mode - standalone or + supervised by run_all_auto script. + print_help Prints the help text for general options. check_for_xorriso [-x] diff --git a/libisoburn/trunk/releng/inc/releng_getopts.inc b/libisoburn/trunk/releng/inc/releng_getopts.inc index 4a87fb20..c6e149f3 100644 --- a/libisoburn/trunk/releng/inc/releng_getopts.inc +++ b/libisoburn/trunk/releng/inc/releng_getopts.inc @@ -7,9 +7,25 @@ RELENG_XORRISO=0 SIMULATE_FAILURE=0 CLEANUP=1 SPECIFIC_HELP=0 - START_DIR_DONT_CHANGE=`pwd` GEN_DATA_DIR=releng_generated_data/${SELF} +RELENG_STANDALONE=1 +RELENG_PARENT=`ps -p $PPID -o comm=` + +############################################# +standalone_or_supervised() { + if test x"$RELENG_PARENT" = x"run_all_auto" + then + echo "${SELF}: Running Supervised by ${RELENG_PARENT}" + RELENG_STANDALONE=0 + else + echo "${SELF}: Running Standalone" + RELENG_STANDALONE=1 + fi +} + +# Unconditionally initialize the invocation mode - standalone or supervised +standalone_or_supervised ############################################# print_help() { @@ -27,10 +43,12 @@ General options: EOF } +############################################# boldify() { if which tput >/dev/null 2>&1; then tput smso; fi } +############################################# unboldify() { if which tput >/dev/null 2>&1; then tput rmso; fi } @@ -85,7 +103,6 @@ cleanup() { } ############################################# - check_for_xorriso() { # $1: if "-x" then check executability