X-Git-Url: http://git.megacz.com/?p=ghc-hetmet.git;a=blobdiff_plain;f=ghc.mk;h=2bea8290e8de29308275a78d206e2c3ef0a9fbd8;hp=f223fd8a76463c34c2bc0c4cbeb0fd5a0053609d;hb=6efacfe8bcbe66dfc3b52397ccbd34a58890520d;hpb=69ba5ae046c4092f544205dd7ce23969bc85b50b diff --git a/ghc.mk b/ghc.mk index f223fd8..2bea829 100644 --- a/ghc.mk +++ b/ghc.mk @@ -53,7 +53,6 @@ # # * 2966 make sure --with-gcc does the right thing (#2966) # * 1693 make distclean -# * 2689 make maintainer-clean # * 3173 make install with DESTDIR # Possible cleanups: @@ -173,6 +172,10 @@ ifneq "$(findstring clean,$(MAKECMDGOALS))" "" NO_INCLUDE_DEPS = YES NO_INCLUDE_PKGDATA = YES endif +ifneq "$(findstring bootstrapping-files,$(MAKECMDGOALS))" "" +NO_INCLUDE_DEPS = YES +NO_INCLUDE_PKGDATA = YES +endif ifeq "$(findstring show,$(MAKECMDGOALS))" "show" NO_INCLUDE_DEPS = YES # We want package-data.mk for show @@ -326,6 +329,7 @@ endif PACKAGES += haskeline +ifneq "$(BootingFromHc)" "YES" PACKAGES_STAGE2 += \ dph/dph-base \ dph/dph-prim-interface \ @@ -333,6 +337,7 @@ PACKAGES_STAGE2 += \ dph/dph-prim-par \ dph/dph-seq \ dph/dph-par +endif BOOT_PKGS = Cabal hpc extensible-exceptions @@ -348,7 +353,8 @@ ifeq "$(BuildSharedLibs)" "YES" OTHER_LIBS += libffi/libHSffi$(dyn_libsuf) endif ifeq "$(HaveLibGmp)" "NO" -OTHER_LIBS += gmp/libgmp.a +GMP_LIB = gmp/libgmp.a +OTHER_LIBS += $(GMP_LIB) endif # We cannot run ghc-cabal to configure a package until we have @@ -493,9 +499,12 @@ BUILD_DIRS += \ ifneq "$(CLEANING)" "YES" BUILD_DIRS += \ - $(patsubst %, libraries/%, $(PACKAGES) $(PACKAGES_STAGE2)) \ + $(patsubst %, libraries/%, $(PACKAGES) $(PACKAGES_STAGE2)) +ifneq "$(BootingFromHc)" "YES" +BUILD_DIRS += \ libraries/dph endif +endif BUILD_DIRS += \ compiler \ @@ -555,7 +564,7 @@ $(foreach pkg,$(PACKAGES) $(PACKAGES_STAGE2),$(eval libraries/$(pkg)_dist-instal # XXX Hack; remove this $(foreach pkg,$(PACKAGES_STAGE2),$(eval libraries/$(pkg)_dist-install_HC_OPTS += -Wwarn)) -# XXX we configure packages with the bootsrapping compiler (for +# XXX we configure packages with the bootstrapping compiler (for # dependency reasons, see the phase ordering), which doesn't # necessarily support all the extensions we need, and Cabal filters # out the ones it thinks aren't supported. @@ -866,7 +875,7 @@ publish-sdist : endif ifeq "$(GhcUnregisterised)" "YES" -SRC_CC_OPTS += -DNO_REGS -DUSE_MINIINTERPRETER +SRC_CC_OPTS += -DNO_REGS -DUSE_MINIINTERPRETER -D__GLASGOW_HASKELL__=$(ProjectVersionInt) endif # ----------------------------------------------------------------------------- @@ -919,3 +928,9 @@ maintainer-clean : distclean .PHONY: all_libraries +.PHONY: bootstrapping-files +bootstrapping-files: $(OTHER_LIBS) +bootstrapping-files: includes/ghcautoconf.h +bootstrapping-files: includes/DerivedConstants.h +bootstrapping-files: includes/GHCConstants.h +