-HASKELL_SPLIT_PRE= \
- if [ ! -d $(basename $@) ]; then mkdir $(basename $@) ; else exit 0; fi; \
- find $(basename $@) -name '*.$(way_)o' -print | xargs $(RM) __rm_food;
-HASKELL_SPLIT_POST= touch $@
-HASKELL_PRE_COMPILE=$(patsubst %,$(HASKELL_SPLIT_PRE),$(filter -split-objs,$(HC_OPTS)))
-HASKELL_POST_COMPILE=$(patsubst %,$(HASKELL_SPLIT_POST),$(filter -split-objs,$(HC_OPTS)))
+# Turn off all the Haskell suffix rules if we're booting from .hc
+# files. The file bootstrap.mk contains alternative suffix rules in
+# this case.
+ifneq "$(BootingFromHc)" "YES"
+
+# The $(odir) support is for building GHC, where we need to build three
+# different versions from the same sources. See ghc/compiler/Makefile.
+ifneq "$(odir)" ""
+odir_ = $(odir)/
+else
+odir_ =
+endif