X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=ghc.mk;h=26dc314a31c14a4dc337486f832bafbe1972a472;hb=07c1b41bc0d960b6e2509332f96f72439fe88864;hp=23d4e5fdc97698b32b6571c08cf645a2f366f2be;hpb=6e232f498ba600e7d7cc4938f5f2e6ce5d300bbc;p=ghc-hetmet.git diff --git a/ghc.mk b/ghc.mk index 23d4e5f..26dc314 100644 --- a/ghc.mk +++ b/ghc.mk @@ -411,7 +411,11 @@ endif # Don't try to delete directories: .PRECIOUS: %/. -%/. : $(MKDIRHIER) +# Create build directories on demand. NB. the | below: this indicates +# that $(MKDIRHIER) is an order-only dependency, which means that this +# rule fires after building mkdirhier, but we won't try to recreate +# directories if mkdirhier changes. +%/. : | $(MKDIRHIER) "$(MKDIRHIER)" $@ # ----------------------------------------------------------------------------- @@ -817,6 +821,8 @@ ifneq "$(INSTALL_LIBRARY_DOCS)" "" for i in $(INSTALL_LIBRARY_DOCS); do \ $(INSTALL_DOC) $(INSTALL_OPTS) $$i "$(DESTDIR)$(docdir)/html/libraries/"; \ done + $(INSTALL_DATA) $(INSTALL_OPTS) libraries/prologue.txt "$(DESTDIR)$(docdir)/html/libraries/" + $(INSTALL_SCRIPT) $(INSTALL_OPTS) libraries/gen_contents_index "$(DESTDIR)$(docdir)/html/libraries/" endif ifneq "$(INSTALL_HTML_DOC_DIRS)" "" for i in $(INSTALL_HTML_DOC_DIRS); do \ @@ -917,6 +923,8 @@ $(eval $(call bindist,.,\ mk/project.mk \ mk/install.mk.in \ bindist.mk \ + libraries/gen_contents_index \ + libraries/prologue.txt \ libraries/dph/LICENSE \ )) endif @@ -1056,7 +1064,13 @@ publish-sdist : endif ifeq "$(BootingFromHc)" "YES" -SRC_CC_OPTS += -DNO_REGS -DUSE_MINIINTERPRETER -D__GLASGOW_HASKELL__=$(ProjectVersionInt) +# In a normal build we use GHC to compile C files (see +# rules/c-suffix-rules.mk), which passes a number of its own options +# to the C compiler. So when bootstrapping we have to provide these +# flags explicitly to C compilations. +SRC_CC_OPTS += -DNO_REGS -DUSE_MINIINTERPRETER +SRC_CC_OPTS += -D__GLASGOW_HASKELL__=$(ProjectVersionInt) +SRC_CC_OPTS += -I$(GHC_INCLUDE_DIR) endif # -----------------------------------------------------------------------------