summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorbringert <unknown>2005-05-12 09:21:26 +0000
committerbringert <unknown>2005-05-12 09:21:26 +0000
commitc7b82c43e2362d105a22cd8d1df47c5588c935aa (patch)
tree6a817a99f0ccd4a049a8f155ea655feb295952a7 /src
parentae60299c7def8a4c2af18320be773158936c6ac9 (diff)
Add optP/optl flags only when needed, and last to avoid ghc 6.2.1
Add optP/optl flags only when needed, and last to avoid ghc 6.2.1 problems.
Diffstat (limited to 'src')
-rw-r--r--src/Makefile12
1 files changed, 10 insertions, 2 deletions
diff --git a/src/Makefile b/src/Makefile
index e8f26034a..e46638981 100644
--- a/src/Makefile
+++ b/src/Makefile
@@ -3,8 +3,7 @@ include config.mk
GHMAKE=$(GHC) --make
GHCXMAKE=ghcxmake
-#GHCFLAGS= -package util -fglasgow-exts -optP'$(CPPFLAGS)' -optl'$(LDFLAGS)'
-GHCFLAGS= -package util -fglasgow-exts
+GHCFLAGS= -fglasgow-exts -package util
GHCOPTFLAGS=-O2
GHCFUDFLAG=
JAVAFLAGS=-target 1.4 -source 1.4
@@ -30,6 +29,15 @@ ifeq ("$(READLINE)","readline")
GHCFLAGS += -package readline -DUSE_READLINE
endif
+ifneq ("$(CPPFLAGS)","")
+ GHCFLAGS += -optP'$(CPPFLAGS)'
+endif
+
+ifneq ("$(LDFLAGS)","")
+ GHCFLAGS += -optl'$(LDFLAGS)'
+endif
+
+
ifeq ("$(ENABLE_JAVA)", "yes")
BUILD_JAR=jar
else