-CURRENT_TARGET = $(MAKECMDGOALS)
-project-check :
- @if [ "$(Project)" = "" ]; then \
- echo " You need to set \"Project\" in order to make $(CURRENT_TARGET)"; \
- echo " eg. make $(CURRENT_TARGET) Project=Ghc"; \
- exit 1; \
- fi
-
-# -----------------------------------------------------------------------------
-# Targets: all, stage1, stage2, stage3
-
-DIST_CLEAN_FILES += config.cache config.status
-
-extraclean::
- $(RM) -rf autom4te.cache
-
-#
-# If you've ended up using an in-place version of Happy,
-# make sure it gets built early on.
-#
-ifeq "$(HAPPY)" "$(FPTOOLS_TOP_ABS)/happy/src/happy-inplace"
-build :: $(FPTOOLS_TOP_ABS)/happy/src/happy-inplace
-
-$(FPTOOLS_TOP_ABS)/happy/src/happy-inplace : glafp-utils
- $(MAKE) -C happy boot all
-endif
+# Sanity check that all the core libraries are in the tree, to catch
+# failure to run darcs-all.
+check-packages :
+ @for d in `cat libraries/core-packages`; do \
+ if test ! -d libraries/$$d; then \
+ echo "Looks like you're missing libraries/$$d,"; \
+ echo "maybe you haven't done 'sh darcs-all get'?"; \
+ exit 1; \
+ fi \
+ done