GNU Make and GNU Indent
authorMarkus Bröker <mbroeker@largo.dyndns.tv>
Tue, 09 Mar 2010 12:58:27 +0100
changeset 122 50ba3b0e271a
parent 121 fef2ccfa7b12
child 123 07b2c0b991af
GNU Make and GNU Indent The Makefile depends on GNU tools and the user may choose the location committer: Markus Bröker <mbroeker@largo.homelinux.org>
Makefile
--- a/Makefile
+++ b/Makefile
@@ -5,6 +5,9 @@
 LDFLAGS = -L/usr/lib
      RM = rm -f
    FIND = find
+   MAKE = make
+ INDENT = indent
+ ERASER = eraser
 
 ifeq ("$(PROFILER)", "linux")
    PROF = -fprofile-arcs -ftest-coverage -pg
@@ -351,9 +354,9 @@
 
 beauty:
 ifdef FIND
-	$(FIND) . -name '*.[ch]' -exec indent {} \;
-	$(FIND) . -name '*.[ch]' -exec eraser {} \;
-	$(FIND) . -name '*.java' -exec eraser {} \;
-	$(FIND) . -name 'Makefile*' -exec eraser {} \;
+	$(FIND) . -name '*.[ch]' -exec $(INDENT) {} \;
+	$(FIND) . -name '*.[ch]' -exec $(ERASER) {} \;
+	$(FIND) . -name '*.java' -exec $(ERASER) {} \;
+	$(FIND) . -name 'Makefile*' -exec $(ERASER) {} \;
 endif
-	@make clean
+	@$(MAKE) clean