diff options
author | Albert Cheng <acheng@hdfgroup.org> | 2003-09-23 13:46:47 (GMT) |
---|---|---|
committer | Albert Cheng <acheng@hdfgroup.org> | 2003-09-23 13:46:47 (GMT) |
commit | 645b7cae4f6de75c3c5203b1a58e46cd8b15d6b6 (patch) | |
tree | 17d86fe3613fba8c01a86bf50029ed9f9e98f176 /bin | |
parent | 4589e4410a230228d72f3e9284a2299704245f99 (diff) | |
download | hdf5-645b7cae4f6de75c3c5203b1a58e46cd8b15d6b6.zip hdf5-645b7cae4f6de75c3c5203b1a58e46cd8b15d6b6.tar.gz hdf5-645b7cae4f6de75c3c5203b1a58e46cd8b15d6b6.tar.bz2 |
[svn-r7505] Purpose:
Fold bug fix (op-configure) and new feature (setenvN)
from development branch.
Description:
setenvN is a general feature to do setenv with N arguments.
Fixed op-configure not to discard the next option argument.
Platforms tested:
Tested fine in development branch.
Will watch the next daily test result.
Misc. update:
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/runtest | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/bin/runtest b/bin/runtest index e42a13e..2e28a20 100755 --- a/bin/runtest +++ b/bin/runtest @@ -301,7 +301,6 @@ RUNSNAPTEST() # option for snapshot shift SNAPCMD_OPT="$SNAPCMD_OPT $1" - shift ;; setenv) # set environment variable @@ -328,6 +327,25 @@ RUNSNAPTEST() export $1 shift; shift; shift ;; + setenvN) + # set environment variable with $1 values + # e.g., setenvN 3 x a b c is same as setenv x="a b c". + # a kludge now--the extra single quotes are needed + # else eval complains. + shift + envN=$1 + shift + envname=$1 + envalue= + while test $envN -gt 0; do + shift + envalue="$envalue $1" + envN=`expr $envN - 1` + done + eval $envname="'$envalue'" + export $envname + export + ;; skip) # skip this test skiptest=yes |