summaryrefslogtreecommitdiff
path: root/utils/ghc-cabal
diff options
context:
space:
mode:
authorIan Lynagh <igloo@earth.li>2009-10-02 19:12:18 +0000
committerIan Lynagh <igloo@earth.li>2009-10-02 19:12:18 +0000
commit883d980815437736c486bf69b2f066ef918d2989 (patch)
tree51590d522003ca6220ff2ee98f29c1c67991fb4c /utils/ghc-cabal
parent6a2a21971ae1a29bf296ecc8652f7cb86b71e7bb (diff)
downloadhaskell-883d980815437736c486bf69b2f066ef918d2989.tar.gz
Use "order only constraints" for directories
There are now 104 calls to mkdirhier, down from 1201, when validating.
Diffstat (limited to 'utils/ghc-cabal')
-rw-r--r--utils/ghc-cabal/ghc.mk10
1 files changed, 3 insertions, 7 deletions
diff --git a/utils/ghc-cabal/ghc.mk b/utils/ghc-cabal/ghc.mk
index c41cd01cd8..71232fb422 100644
--- a/utils/ghc-cabal/ghc.mk
+++ b/utils/ghc-cabal/ghc.mk
@@ -18,13 +18,10 @@ CABAL_DOTTED_VERSION := $(shell grep "^Version:" libraries/Cabal/Cabal.cabal | s
CABAL_VERSION := $(subst .,$(comma),$(CABAL_DOTTED_VERSION))
CABAL_CONSTRAINT := --constraint="Cabal == $(CABAL_DOTTED_VERSION)"
-$(GHC_CABAL_INPLACE) : $(GHC_CABAL_DIR)/dist/build/tmp/ghc-cabal$(exeext)
- "$(MKDIRHIER)" $(dir $@)
+$(GHC_CABAL_INPLACE) : $(GHC_CABAL_DIR)/dist/build/tmp/ghc-cabal$(exeext) | $$(dir $$@)/.
"$(CP)" $< $@
-$(GHC_CABAL_DIR)/dist/build/tmp/ghc-cabal$(exeext): $(GHC_CABAL_DIR)/ghc-cabal.hs $(MKDIRHIER)
- "$(MKDIRHIER)" bootstrapping
- "$(MKDIRHIER)" $(dir $@)
+$(GHC_CABAL_DIR)/dist/build/tmp/ghc-cabal$(exeext): $(GHC_CABAL_DIR)/ghc-cabal.hs | $$(dir $$@)/. bootstrapping/.
"$(GHC)" $(SRC_HC_OPTS) --make $(GHC_CABAL_DIR)/ghc-cabal.hs -o $@ \
-Wall $(WERROR) \
-DCABAL_VERSION=$(CABAL_VERSION) \
@@ -54,8 +51,7 @@ $(GHC_CABAL_DIR)_dist-dummy-ghc_MODULES = dummy-ghc
$(GHC_CABAL_DIR)_dist-dummy-ghc_PROG = dummy-ghc$(exeext)
# depend on project.mk, so we pick up the new version number if it changes.
-$(GHC_CABAL_DIR)/dist-dummy-ghc/build/dummy-ghc.hs : $(GHC_CABAL_DIR)/ghc.mk $(MKDIRHIER) mk/project.mk
- "$(MKDIRHIER)" $(dir $@)
+$(GHC_CABAL_DIR)/dist-dummy-ghc/build/dummy-ghc.hs : $(GHC_CABAL_DIR)/ghc.mk mk/project.mk | $$(dir $$@)/.
echo "import System.Environment; import System.Cmd; import System.Exit" >$@
echo "main :: IO ()" >>$@
echo "main = do args <- getArgs; if args == [\"--numeric-version\"] then putStrLn \"$(ProjectVersion)\" else do e <- rawSystem \"$(GHC_STAGE0)\" args; exitWith e" >>$@