diff options
author | Greg Troxel <gdt@ir.bbn.com> | 2011-03-03 10:05:00 -0500 |
---|---|---|
committer | Greg Troxel <gdt@ir.bbn.com> | 2011-03-03 10:05:00 -0500 |
commit | 9652900a4458b5a31300b2db558b8b70bd9b8bfb (patch) | |
tree | 8b4fc0c5da2ae1560b504a78ebd007763187a03a /regress-driver | |
parent | 31d45eccfef462f3a7d022f29c2d1cd3e2ef2d3f (diff) | |
download | gpsd-9652900a4458b5a31300b2db558b8b70bd9b8bfb.tar.gz |
Don't assume python scripts in source tree are directly runnable.
Use ${PYTHON} to invoke scripts, because the sources have
"/usr/bin/env python", and a sane approach to the python version
incompatibility nightmare is to a) decline to have a program named
python and to b) force all python programs to pick a version at
configure time and stick with it. (Otherwise you break installed
programs when the default changes, or have to go through some
difficult-to-prove-correct update process.)
With this, regression tests at least begin to run sanely instead of
all failing miserably (on NetBSD/pkgsrc).
Diffstat (limited to 'regress-driver')
-rwxr-xr-x | regress-driver | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/regress-driver b/regress-driver index 524b77c1..b6bed51f 100755 --- a/regress-driver +++ b/regress-driver @@ -105,8 +105,8 @@ case $mode in then trap 'rm -f ${TMP}/test-$$.chk; exit $errors' EXIT HUP INT TERM case $testing in - daemon) ${GPSD_HOME}/gpsfake -s 38400 -1 -p $opts ${f} | ${GPSFILTER} ${ALTFILTER} >${TMP}/test-$$.chk ;; - clientlib) ${GPSD_HOME}/libgps -b <${f} >${TMP}/test-$$.chk ;; + daemon) ${PYTHON} ${GPSD_HOME}/gpsfake -s 38400 -1 -p $opts ${f} | ${GPSFILTER} ${ALTFILTER} >${TMP}/test-$$.chk ;; + clientlib) ${PYTHON} ${GPSD_HOME}/libgps -b <${f} >${TMP}/test-$$.chk ;; esac if [ "${ALTFILTER}" ] then @@ -152,7 +152,7 @@ case $mode in superraw) echo "Testing super-raw mode..." >&2 for f in $*; do - ${GPSD_HOME}/gpsfake -s 38400 -1 -p $opts -r '{"class":"WATCH","enable":False,"raw":2}' $opts ${f} \ + ${PYTHON} ${GPSD_HOME}/gpsfake -s 38400 -1 -p $opts -r '{"class":"WATCH","enable":False,"raw":2}' $opts ${f} \ | ./devtools/striplog -1 >${TMP}/test1-$$.chk; ./devtools/striplog <${f} >${TMP}/test2-$$.chk; cmp ${TMP}/test[12]-$$.chk; @@ -162,8 +162,8 @@ case $mode in echo "Rebuilding $testing regressions..." >&2 for f in $*; do case $testing in - daemon) ${GPSD_HOME}/gpsfake -s 38400 -1 -p $opts ${f} | ${GPSFILTER} >${f}.chk;; - clientlib) ${GPSD_HOME}/libgps -b <${f} >${f}.chk ;; + daemon) ${PYTHON} ${GPSD_HOME}/gpsfake -s 38400 -1 -p $opts ${f} | ${GPSFILTER} >${f}.chk;; + clientlib) ${PYTHON} ${GPSD_HOME}/libgps -b <${f} >${f}.chk ;; esac done status=0 @@ -172,8 +172,8 @@ case $mode in echo "Viewing..." >&2 for f in $*; do case $testing in - daemon) ${GPSD_HOME}/gpsfake -s 38400 -1 -p $opts ${f} | ${GPSFILTER} ;; - clientlib) ${GPSD_HOME}/libgps -b <${f} ;; + daemon) ${PYTHON} ${GPSD_HOME}/gpsfake -s 38400 -1 -p $opts ${f} | ${GPSFILTER} ;; + clientlib) ${PYTHON} ${GPSD_HOME}/libgps -b <${f} ;; esac done status=0 |