X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=compiler%2FMakefile;h=f330340b33728653b1c4d707f3920c047adf2716;hb=46b28f7bfdd535e9fe5217a1151bedfb2cc15472;hp=9b24c78411eb74c6e49310bfa1a93ad0d9a2b5d7;hpb=4a88ae96833c8f7b18de46c29e805bb53f8b5669;p=ghc-hetmet.git diff --git a/compiler/Makefile b/compiler/Makefile index 9b24c78..f330340 100644 --- a/compiler/Makefile +++ b/compiler/Makefile @@ -406,15 +406,15 @@ endif # ----------------------------------------------------------------------------- # Building a compiler with interpreter support # -# The interpreter, GHCi interface, and Template Haskell are only +# The interpreter, GHCi interface, Template Haskell and Hpc are only # enabled when we are bootstrapping with the same version of GHC, and # the interpreter is supported on this platform. ifeq "$(GhcWithInterpreter) $(bootstrapped)" "YES YES" # Yes, include the interepreter, readline, and Template Haskell extensions -SRC_HC_OPTS += -DGHCI -package template-haskell -PKG_DEPENDS += template-haskell +SRC_HC_OPTS += -DGHCI -package template-haskell -package hpc +PKG_DEPENDS += template-haskell hpc # Should GHCI be building info tables in the TABLES_NEXT_TO_CODE style # or not? @@ -702,8 +702,6 @@ SRC_LD_OPTS += -no-link-chk # See comments in $(FPTOOLS_TOP)/utils/ghc-pkg/Makefile for why we use # a real binary here rather than a shell script. -all :: $(odir)/ghc-inplace ghc-inplace - INPLACE_HS = $(odir)/ghc-inplace.hs INPLACE_PROG = $(odir)/ghc-inplace$(exeext) EXCLUDED_SRCS += $(INPLACE_HS) @@ -713,8 +711,8 @@ EXCLUDED_SRCS += $(INPLACE_HS) TOP_ABS=$(subst \\,/,$(FPTOOLS_TOP_ABS_PLATFORM)) $(INPLACE_HS): Makefile $(FPTOOLS_TOP)/mk/config.mk - echo "import System.Cmd; import System.Environment" > $@ - echo "main = getArgs >>= \args -> rawSystem \"$(TOP_ABS)/$(GHC_COMPILER_DIR_REL)/$(GHC_PROG)\" (\"-B$(TOP_ABS)\":args)" >> $@ + echo "import System.Cmd; import System.Environment; import System.Exit" > $@ + echo "main = do args <- getArgs; rawSystem \"$(TOP_ABS)/$(GHC_COMPILER_DIR_REL)/$(GHC_PROG)\" (\"-B$(TOP_ABS)\":args) >>= exitWith" >> $@ $(INPLACE_PROG): $(INPLACE_HS) $(GHC) --make $< -o $@ @@ -727,6 +725,8 @@ ifeq "$(stage)" "1" ghc-inplace : $(INPLACE_PROG) $(RM) -f $@ && $(LN_S) $< $@ +all :: ghc-inplace + CLEAN_FILES += ghc-inplace endif