~ chicken-core (chicken-5) 9c548ea1a1f532cd4424b1627ca8d1a46dd9fac7
commit 9c548ea1a1f532cd4424b1627ca8d1a46dd9fac7
Author: Peter Bex <Peter.Bex@xs4all.nl>
AuthorDate: Sun Sep 5 12:25:01 2010 +0200
Commit: Peter Bex <Peter.Bex@xs4all.nl>
CommitDate: Sun Sep 5 12:25:01 2010 +0200
Make use of GNU Make's own looping constructs and info/error message system. This avoids needing to rely on the shell to perform wildcard expansion and looping which I understand Windows doesn't know how to do
diff --git a/GNUmakefile b/GNUmakefile
index ea932bf0..76c1a4d9 100644
--- a/GNUmakefile
+++ b/GNUmakefile
@@ -34,19 +34,14 @@ include $(CONFIG)
endif
ifndef PLATFORM
-no-platform:
- @echo "No PLATFORM given."
- @echo ""
- @echo "Please select your target platform by running one of the following commands:"
- @echo ""
- @for mf in Makefile.*; do \
- echo " $(MAKE) PLATFORM=$${mf#Makefile.}"; \
- done
- @echo ""
- @echo "For more information, consult the README file."
- @exit 1
-%: no-platform ;
-else
+$(info Please select your target platform by running one of the following commands:)
+$(info )
+$(foreach mf, $(wildcard Makefile.*), $(info $(MAKE) PLATFORM=$(mf)))
+$(info )
+$(info For more information, consult the README file.)
+$(error No PLATFORM given.)
+endif
+
SRCDIR = .
STANDARD_TARGETS \
@@ -64,5 +59,3 @@ dist:
boot-chicken:
$(MAKE) -f $(SRCDIR)/Makefile.$(PLATFORM) boot-chicken
-
-endif
\ No newline at end of file
Trap