1 # -----------------------------------------------------------------------------
3 # (c) 2009 The University of Glasgow
5 # This file is part of the GHC build system.
7 # To understand how the build system works and how to modify it, see
8 # http://hackage.haskell.org/trac/ghc/wiki/Building/Architecture
9 # http://hackage.haskell.org/trac/ghc/wiki/Building/Modifying
11 # -----------------------------------------------------------------------------
13 ifeq "$(wildcard distrib/)" ""
19 @echo 'Run "make install" to install'
24 $(MAKE) -r --no-print-directory -f ghc.mk install BINDIST=YES NO_INCLUDE_DEPS=YES
28 $(MAKE) -r --no-print-directory -f ghc.mk $@
35 # No need to update makefiles for these targets:
36 REALGOALS=$(filter-out clean clean_% distclean maintainer-clean show,$(MAKECMDGOALS))
38 # NB. not the same as saying '%: ...', which doesn't do the right thing:
39 # it does nothing if we specify a target that already exists.
42 @echo "===--- updating makefiles phase 0"
43 $(MAKE) -r --no-print-directory -f ghc.mk phase=0 just-makefiles
44 @echo "===--- updating makefiles phase 1"
45 $(MAKE) -r --no-print-directory -f ghc.mk phase=1 just-makefiles
46 @echo "===--- updating makefiles phase 2"
47 $(MAKE) -r --no-print-directory -f ghc.mk phase=2 just-makefiles
48 @echo "===--- updating makefiles phase 3"
49 $(MAKE) -r --no-print-directory -f ghc.mk phase=3 just-makefiles
50 @echo "===--- finished updating makefiles"
51 $(MAKE) -r --no-print-directory -f ghc.mk $@
55 $(MAKE) -r --no-print-directory -f ghc.mk bindist BINDIST=YES
56 $(MAKE) -r --no-print-directory -f ghc.mk binary-dist
58 clean distclean maintainer-clean:
59 $(MAKE) -r --no-print-directory -f ghc.mk $@
60 test ! -d testsuite || $(MAKE) -C testsuite $@
62 $(filter clean_%, $(MAKECMDGOALS)) : clean_% :
63 $(MAKE) -r --no-print-directory -f ghc.mk $@
66 $(MAKE) -r --no-print-directory -f ghc.mk $@
68 # If the user says 'make A B', then we don't want to invoke two
69 # instances of the rule above in parallel: