define build-prog
$(call trace, build-prog($1,$2,$3))
+$(call profStart, build-prog($1,$2,$3))
# $1 = dir
# $2 = distdir
# $3 = GHC stage to use (0 == bootstrapping compiler)
ifneq "$$($1_$2_NOT_NEEDED)" "YES"
$$(eval $$(call build-prog-helper,$1,$2,$3))
endif
+$(call profEnd, build-prog($1,$2,$3))
endef
ifneq "$$(NO_INCLUDE_PKGDATA)" "YES"
ifeq "$3" "0"
include $1/$2/package-data.mk
-else ifeq "$(phase)" ""
+else ifeq "$(phase)" "final"
include $1/$2/package-data.mk
endif
endif
# bootstrapping stuff
ifeq "$3" "0"
$(call include-dependencies,$1,$2,$3)
-else ifeq "$(phase)" ""
+else ifeq "$(phase)" "final"
# In the final phase, we also include the dependency files for
# everything else
$(call include-dependencies,$1,$2,$3)