diff options
author | Eric S. Raymond <esr@thyrsus.com> | 2013-11-30 12:05:44 -0500 |
---|---|---|
committer | Eric S. Raymond <esr@thyrsus.com> | 2013-11-30 12:05:44 -0500 |
commit | 20e08248a6466c174ebef11b08bcd31668f8de98 (patch) | |
tree | 3d70f5a1eefc352ee873f2c53ff2e3607a95cf8d | |
parent | 4a93e85cca1c9d79e4a1a024a9fbfd5dd1c112e8 (diff) | |
download | gpsd-20e08248a6466c174ebef11b08bcd31668f8de98.tar.gz |
Belt-and-suspenders setting of LD_LIBRARY_PATH for regression testing.
-rw-r--r-- | SConstruct | 13 | ||||
-rwxr-xr-x | regress-driver | 4 |
2 files changed, 12 insertions, 5 deletions
@@ -481,11 +481,14 @@ else: env.Prepend(LIBPATH=[os.path.realpath(os.curdir)]) if env["shared"] and env["chrpath"]: if WhereIs('chrpath'): - # Tell generated binaries to look in the current directory for - # shared libraries so we can run regression tests without - # hassle. Should be handled sanely by scons on all systems. Not - # good to use '.' or a relative path here; it's a security risk. - # At install time we use chrpath to edit this out of RPATH. + # Tell generated binaries to look in the current directory + # for shared libraries so we can run ad-hoc tests without + # hassle (the regression tests *don't* need this as + # they're run in a controlled environment where we can set + # LD_LIBRARY_PATH). Should be handled sanely by scons on + # all systems. Not good to use '.' or a relative path + # here; it's a security risk. At install time we use + # chrpath to edit this out of RPATH. env.Prepend(RPATH=[os.path.realpath(os.curdir)]) else: print "chrpath is not available; please build with chrpath=no." diff --git a/regress-driver b/regress-driver index af4feb28..453b932a 100755 --- a/regress-driver +++ b/regress-driver @@ -15,6 +15,10 @@ else GPSD_HOME=`dirname $0` fi +# Avoid dynamic-linking failures if we don't happen to have the GPSD +# libraries installed in system space yet. +export LD_LIBRARY_PATH=$GPSD_HOME + # Arrange to call a gpsfake in the source directory without fuss. if [ -z ${PYTHON} ]; then PYTHON="python" |