summaryrefslogtreecommitdiffstats
path: root/Makefile.in
diff options
context:
space:
mode:
authorP. J. McDermott <pjm@nac.net>2012-01-25 03:47:44 (EST)
committer P. J. McDermott <pjm@nac.net>2012-01-25 03:47:44 (EST)
commita991b8c9a1a0019ef1a36bbec49c29827a3c57a2 (patch)
tree4024d15aff81bbf9335ddfb7eae15e2667ce281d /Makefile.in
parentaa8b08354c087d5baaf904fffeeb5b0d074adb9e (diff)
Recurse into subdirectories in build system.
Diffstat (limited to 'Makefile.in')
-rw-r--r--Makefile.in32
1 files changed, 20 insertions, 12 deletions
diff --git a/Makefile.in b/Makefile.in
index af9b635..77a7368 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -33,11 +33,11 @@ MAKE = @make@
.PHONY: all
all: sedscript
@printf 'Making executable files...\n'
- @$(MAKE) -f src/Makefile all
+ @cd src && $(MAKE) all
@printf 'Making library files...\n'
- @$(MAKE) -f lib/Makefile all
+ @cd lib && $(MAKE) all
@printf 'Making manual pages...\n'
- @$(MAKE) -f man/Makefile all
+ @cd man && $(MAKE) all
sedscript:
@printf 'Writing sed script...\n'
@@ -46,27 +46,35 @@ sedscript:
.PHONY: clean
clean:
+ @printf 'Deleting sed script...\n'
+ @rm -f sedscript
@printf 'Cleaning executable files...\n'
- @$(MAKE) -f src/Makefile clean
+ @cd src && $(MAKE) clean
@printf 'Cleaning library files...\n'
- @$(MAKE) -f lib/Makefile clean
+ @cd lib && $(MAKE) clean
@printf 'Cleaning manual pages...\n'
- @$(MAKE) -f man/Makefile clean
+ @cd man && $(MAKE) clean
.PHONY: install
install: all
+ @printf 'Generating installation configuration...\n'
+ @echo '' > install.config
+ @if [ -n '$(DESTDIR)' ]; then \
+ mkdir -p '$(DESTDIR)'; \
+ echo "DESTDIR=$$(cd '$(DESTDIR)' && pwd)" >> install.config; \
+ fi
@printf 'Installing executable files...\n'
- @$(MAKE) -f src/Makefile install
+ @cd src && $(MAKE) $$(cat ../install.config) install
@printf 'Installing libary files...\n'
- @$(MAKE) -f lib/Makefile install
+ @cd lib && $(MAKE) $$(cat ../install.config) install
@printf 'Installing manual pages...\n'
- @$(MAKE) -f man/Makefile install
+ @cd man && $(MAKE) $$(cat ../install.config) install
.PHONY: uninstall
uninstall:
@printf 'Uninstalling executable files...\n'
- @$(MAKE) -f src/Makefile uninstall
+ @cd src && $(MAKE) uninstall
@printf 'Uninstalling library files...\n'
- @$(MAKE) -f lib/Makefile uninstall
+ @cd lib && $(MAKE) uninstall
@printf 'Uninstalling manual pages...\n'
- @$(MAKE) -f man/Makefile uninstall
+ @cd man && $(MAKE) uninstall