X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=ghc.mk;h=3214c656e24d1c12f2237335ec96e16ce842f9f1;hb=9eba9078e1993db58b8e12e9287f448df64a4fb6;hp=9a5210533d0858a99fd92a4f1742421de58089dc;hpb=712ea2a4c7b7d0e90f9651ce9618dd31bc07562f;p=ghc-hetmet.git diff --git a/ghc.mk b/ghc.mk index 9a52105..3214c65 100644 --- a/ghc.mk +++ b/ghc.mk @@ -349,20 +349,28 @@ $(eval $(call addPackage,haskeline)) $(foreach pkg,$(EXTRA_PACKAGES),$(eval $(call addPackage,$(pkg)))) -ifneq "$(BootingFromHc)" "YES" -ifneq "$(GhcProfiled)" "YES" -# DPH uses Template Haskell, and Template Haskell doesn't work -# with a profiled compiler. So if stage-2 is profile, don't build DPH -PACKAGES_STAGE2 += \ - dph/dph-base \ +# ------------------- Adding DPH packaes --------------- +DPH_PACKAGES = dph/dph-base \ dph/dph-prim-interface \ dph/dph-prim-seq \ dph/dph-prim-par \ dph/dph-seq \ dph/dph-par -endif -endif +ifneq "$(BootingFromHc)" "YES" +ifeq "$(CLEANING)" "YES" +# If we are cleaning we must add DPH packages regardless, +# for reasons we now forget +PACKAGES_STAGE2 += $(DPH_PACKAGES) +else # not CLEANING +ifneq "$(GhcProfiled)" "YES" +# DPH uses Template Haskell, and Template Haskell doesn't work +# with a profiled compiler. So if stage-2 is profile, don't build DPH +PACKAGES_STAGE2 += $(DPH_PACKAGES) +endif # GhcProfiled +endif # Cleaning +endif # BootingFromHc +# ------------------------------------------------------- # We assume that the stage0 compiler has a suitable bytestring package, # so we don't have to include it below.