summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
authorIan Lynagh <ian@well-typed.com>2013-03-20 19:25:27 +0000
committerIan Lynagh <ian@well-typed.com>2013-03-20 19:25:27 +0000
commit51bf3653775ba734f7ca3de99234aba722a0c72c (patch)
tree5f86e5ce5e8f9301f861d96fee6d2980ed23eb10 /mk
parent0f49dd691a364ec28007470aabe4fd9fed56e603 (diff)
downloadhaskell-51bf3653775ba734f7ca3de99234aba722a0c72c.tar.gz
Fix build with non-Linux ELF OSes
We were only setting an RPATH for the RTS DLL on Linux, but as far as I can see we should be doing it for all ELF OSes. Hopefully this will fix the problem where the installed ghc-pkg can't find libffi.dll on FreeBSD.
Diffstat (limited to 'mk')
-rw-r--r--mk/config.mk.in8
1 files changed, 7 insertions, 1 deletions
diff --git a/mk/config.mk.in b/mk/config.mk.in
index c818a32d6f..275c21a803 100644
--- a/mk/config.mk.in
+++ b/mk/config.mk.in
@@ -88,7 +88,13 @@ GhcDynamic=NO
# GhcProfiled=YES means compile a profiled stage-2 compiler
GhcProfiled=NO
-# Soem platforms don't support shared libraries
+ifeq "$(findstring $(TargetOS_CPP),linux freebsd dragonfly openbsd netbsd solaris2 kfreebsdgnu haiku linux-android)" ""
+TargetElf = NO
+else
+TargetElf = YES
+endif
+
+# Some platforms don't support shared libraries
NoSharedLibsPlatformList =
ifeq "$(SOLARIS_BROKEN_SHLD)" "YES"