Add some missing dependencies
[ghc-hetmet.git] / rules / include-dependencies.mk
1 # -----------------------------------------------------------------------------
2 #
3 # (c) 2009 The University of Glasgow
4 #
5 # This file is part of the GHC build system.
6 #
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
10 #
11 # -----------------------------------------------------------------------------
12
13 define include-dependencies
14 $(call trace, include-dependencies($1,$2,$3))
15 # $1 = dir
16 # $2 = distdir
17 # $3 = GHC stage to use (0 == bootstrapping compiler)
18
19 ifneq "$$(NO_INCLUDE_DEPS)" "YES"
20 ifneq "$$(strip $$($1_$2_HS_SRCS) $$($1_$2_HS_BOOT_SRCS))" ""
21 ifneq "$$(NO_STAGE$3_DEPS)" "YES"
22 include $$($1_$2_depfile_haskell)
23 endif
24 endif
25 include $$($1_$2_depfile_c_asm)
26 else
27 ifeq "$$(DEBUG)" "YES"
28 $$(warning not building dependencies in $1)
29 endif
30 endif
31
32 endef
33