summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--rules/library-path.mk7
-rw-r--r--testsuite/driver/runtests.py7
2 files changed, 5 insertions, 9 deletions
diff --git a/rules/library-path.mk b/rules/library-path.mk
index 9a398eebf0..92511f2c94 100644
--- a/rules/library-path.mk
+++ b/rules/library-path.mk
@@ -13,9 +13,8 @@
# $1 = paths to prepend
ifeq "$(TargetOS_CPP)" "mingw32"
prependLibraryPath = $(error Do not know how to prependLibraryPath on Windows)
-else ifeq "$(TargetOS_CPP)" "darwin"
-prependLibraryPath = export DYLD_LIBRARY_PATH="$1$${DYLD_LIBRARY_PATH:+:$$DYLD_LIBRARY_PATH}"
-else
+else ifneq "$(TargetOS_CPP)" "darwin"
prependLibraryPath = export LD_LIBRARY_PATH="$1$${LD_LIBRARY_PATH:+:$$LD_LIBRARY_PATH}"
+else
+prependLibraryPath =
endif
-
diff --git a/testsuite/driver/runtests.py b/testsuite/driver/runtests.py
index 5ef6ca27bf..5f059e58d4 100644
--- a/testsuite/driver/runtests.py
+++ b/testsuite/driver/runtests.py
@@ -238,7 +238,7 @@ def format_path(path):
# On Windows we need to set $PATH to include the paths to all the DLLs
# in order for the dynamic library tests to work.
-if windows or darwin:
+if windows:
pkginfo = getStdout([config.ghc_pkg, 'dump'])
topdir = config.libdir
if windows:
@@ -256,12 +256,9 @@ if windows or darwin:
if path.startswith('"'):
path = re.sub('^"(.*)"$', '\\1', path)
path = re.sub('\\\\(.)', '\\1', path)
- if windows:
+
path = format_path(path)
ghc_env['PATH'] = os.pathsep.join([path, ghc_env.get("PATH", "")])
- else:
- # darwin
- ghc_env['DYLD_LIBRARY_PATH'] = os.pathsep.join([path, ghc_env.get("DYLD_LIBRARY_PATH", "")])
testopts_local.x = TestOptions()