[commit: ghc] master: Tweak the _HC_OPTS variables (9548ec5)
Ian Lynagh
igloo at earth.li
Sat Mar 23 15:00:15 CET 2013
Repository : http://darcs.haskell.org/ghc.git/
On branch : master
https://github.com/ghc/ghc/commit/9548ec53d31b478bd22a4dd9cbce1244db013b67
>---------------------------------------------------------------
commit 9548ec53d31b478bd22a4dd9cbce1244db013b67
Author: Ian Lynagh <ian at well-typed.com>
Date: Sat Mar 23 11:56:46 2013 +0000
Tweak the _HC_OPTS variables
We no longer pass -hisuf/-osuf flags to "ghc -M". Doing so didn't really
make sense with the way the -dep-suffix flags now work.
>---------------------------------------------------------------
rules/build-dependencies.mk | 2 +-
rules/distdir-way-opts.mk | 13 ++++++++-----
2 files changed, 9 insertions(+), 6 deletions(-)
diff --git a/rules/build-dependencies.mk b/rules/build-dependencies.mk
index 7bbb8c5..bb047f6 100644
--- a/rules/build-dependencies.mk
+++ b/rules/build-dependencies.mk
@@ -35,7 +35,7 @@ $$($1_$2_depfile_haskell) : $$($1_$2_HS_SRCS) $$($1_$2_HS_BOOT_SRCS) $$($1_$2_HC
$$(call removeFiles,$$@.tmp)
ifneq "$$($1_$2_HS_SRCS)" ""
"$$($1_$2_HC_MK_DEPEND)" -M \
- $$(filter-out -split-objs, $$($1_$2_$$(firstword $$($1_$2_WAYS))_ALL_HC_OPTS)) \
+ $$($1_$2_$$(firstword $$($1_$2_WAYS))_MOST_DIR_HC_OPTS) \
$$($1_$2_MKDEPENDHS_FLAGS) \
$$($1_$2_HS_SRCS)
endif
diff --git a/rules/distdir-way-opts.mk b/rules/distdir-way-opts.mk
index 17ac70c..872e527 100644
--- a/rules/distdir-way-opts.mk
+++ b/rules/distdir-way-opts.mk
@@ -99,7 +99,6 @@ $1_$2_$3_MOST_HC_OPTS = \
$$(foreach opt,$$($1_$2_CPP_OPTS),-optP$$(opt)) \
$$(if $$($1_PACKAGE),-optP-include -optP$1/$2/build/autogen/cabal_macros.h) \
$$(foreach pkg,$$($1_$2_DEPS),-package $$(pkg)) \
- $$(if $$(findstring YES,$$($1_$2_SplitObjs)),$$(if $$(findstring dyn,$3),,-split-objs),) \
$$($1_$2_HC_OPTS) \
$$(CONF_HC_OPTS_STAGE$4) \
$$($1_$2_MORE_HC_OPTS) \
@@ -109,16 +108,20 @@ $1_$2_$3_MOST_HC_OPTS = \
$$(SRC_HC_WARNING_OPTS) \
$$(EXTRA_HC_OPTS)
+$1_$2_$3_MOST_DIR_HC_OPTS = \
+ $$($1_$2_$3_MOST_HC_OPTS) \
+ -odir $1/$2/build -hidir $1/$2/build -stubdir $1/$2/build
+
# NB. CONF_HC_OPTS_STAGE$4 has to be late enough to override $1_$2_HC_OPTS, so
# that -O0 is effective (see #5484)
# $1_$2_$3_ALL_HC_OPTS: this is all the options we will pass to GHC
# for a given ($1,$2,$3).
$1_$2_$3_ALL_HC_OPTS = \
- $$($1_$2_$3_MOST_HC_OPTS) \
- $$(if $$(findstring YES,$$($1_$2_DYNAMIC_TOO)),$$(if $$(findstring v,$3),-dynamic-too)) \
- -odir $1/$2/build -hidir $1/$2/build -stubdir $1/$2/build \
- -hisuf $$($3_hisuf) -osuf $$($3_osuf) -hcsuf $$($3_hcsuf)
+ -hisuf $$($3_hisuf) -osuf $$($3_osuf) -hcsuf $$($3_hcsuf) \
+ $$($1_$2_$3_MOST_DIR_HC_OPTS) \
+ $$(if $$(findstring YES,$$($1_$2_SplitObjs)),$$(if $$(findstring dyn,$3),,-split-objs),) \
+ $$(if $$(findstring YES,$$($1_$2_DYNAMIC_TOO)),$$(if $$(findstring v,$3),-dynamic-too))
ifeq "$3" "dyn"
ifneq "$4" "0"
More information about the ghc-commits
mailing list