diff options
Diffstat (limited to 'run_tests.sh.in')
-rw-r--r-- | run_tests.sh.in | 66 |
1 files changed, 36 insertions, 30 deletions
diff --git a/run_tests.sh.in b/run_tests.sh.in index 1562eeec6..35e24d794 100644 --- a/run_tests.sh.in +++ b/run_tests.sh.in @@ -75,50 +75,56 @@ do fi done -# Add the grlibdir paths to the front of any PATH variable -if [ "$grlibdir" != "" ] -then - # For OS/X - if [ "$DYLD_LIBRARY_PATH" = "" ] - then - DYLD_LIBRARY_PATH=$grlibdir - else - DYLD_LIBRARY_PATH=$grlibdir:$DYLD_LIBRARY_PATH - fi - - # For Win32 - if [ "$PATH" = "" ] - then - PATH=$grlibdir - else - PATH=$grlibdir:$PATH - fi -fi +# Add 'mylibdir' to the start of the library load path, to get local +# (to this component) created libraries # Where to find pre-installed libraries withlibdirs=@with_LIBDIRPATH@ -# Add the withdirs paths to the end of any PATH variable -if [ "$withlibdirs" != "" ] -then - # For OS/X +case "@host_os@" in + darwin*) + # Special Code for executing on Darwin / Mac OS X only if [ "$DYLD_LIBRARY_PATH" = "" ] then - DYLD_LIBRARY_PATH=$withlibdirs + DYLD_LIBRARY_PATH=$mylibdir else + DYLD_LIBRARY_PATH=$mylibdir:$DYLD_LIBRARY_PATH + fi + # DYLD_LIBRARY_PATH will not be empty now + # Add the grlibdir paths to the front of any library load variable + if [ "$grlibdir" != "" ] + then + DYLD_LIBRARY_PATH=$grlibdir:$DYLD_LIBRARY_PATH + fi + # Add the withdirs paths to the end of any library load variable + if [ "$withlibdirs" != "" ] + then DYLD_LIBRARY_PATH=$DYLD_LIBRARY_PATH:$withlibdirs fi - - # For Win32 + export DYLD_LIBRARY_PATH + ;; + cygwin*|win*|mingw*) + # Special Code for executing on Win32 variants only if [ "$PATH" = "" ] then - PATH=$withlibdirs + PATH=$mylibdir else + PATH=$mylibdir:$PATH + fi + # PATH will not be empty now + # Add the grlibdir paths to the front of any library load variable + if [ "$grlibdir" != "" ] + then + PATH=$grlibdir:$PATH + fi + # Add the withdirs paths to the end of any library load variable + if [ "$withlibdirs" != "" ] + then PATH=$PATH:$withlibdirs fi -fi - -export DYLD_LIBRARY_PATH + export PATH + ;; +esac # Don't load user or system prefs GR_DONT_LOAD_PREFS=1 |