aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>1997-10-06 21:05:49 +0000
committerH. Peter Anvin <hpa@zytor.com>1997-10-06 21:05:49 +0000
commitbddd43e289c8b8b62d7cb3f1f7eb27ca67cae28e (patch)
treeaac5e4a4b924cb13a54cc0760e99f349ea36bd12 /Makefile
downloadautofs3-bddd43e289c8b8b62d7cb3f1f7eb27ca67cae28e.tar.gz
autofs3-bddd43e289c8b8b62d7cb3f1f7eb27ca67cae28e.tar.xz
autofs3-bddd43e289c8b8b62d7cb3f1f7eb27ca67cae28e.zip
Initial revision
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile69
1 files changed, 69 insertions, 0 deletions
diff --git a/Makefile b/Makefile
new file mode 100644
index 0000000..7da800c
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,69 @@
+SUBDIRS = daemon modules man
+INCDIRS = include samples
+INCFILES = COPYING COPYRIGHT NEWS README TODO Makefile Makefile.rules \
+ .version *.diff
+
+.PHONY: daemon all kernel clean install install_kernel mrproper
+.PHONY: distclean backup
+
+daemon:
+ for i in $(SUBDIRS); do $(MAKE) -C $$i all; done
+
+kernel:
+ if [ -d kernel ]; then $(MAKE) -C kernel all; fi
+
+all: daemon kernel
+
+clean:
+ for i in $(SUBDIRS) kernel; do \
+ if [ -d $$i ]; then $(MAKE) -C $$i clean; fi; done
+
+install:
+ for i in $(SUBDIRS); do $(MAKE) -C $$i install; done
+
+install_kernel:
+ if [ -d kernel ]; then $(MAKE) -C kernel install; fi
+
+mrproper distclean: clean
+ find . -noleaf \( -name '*~' -o -name '#*' -o -name '*.orig' -o -name '*.rej' -o -name '*.old' \) -print0 | xargs -0 rm -f
+
+TODAY := $(shell date +'%Y%m%d')
+
+backup: mrproper
+ cd .. ; tar cf - autofs | gzip -9 > autofs-bu-$(TODAY).tar.gz
+
+RELEASE := $(shell cat .version)
+
+.PHONY: release newrelease
+
+reldir:
+ -rm -rf autofs-$(RELEASE) autofs-$(RELEASE).tar.gz
+ mkdir autofs-$(RELEASE)
+ cp -R $(SUBDIRS) $(INCDIRS) $(INCFILES) autofs-$(RELEASE)
+ $(MAKE) -C autofs-$(RELEASE) distclean
+ find autofs-$(RELEASE) -noleaf -name \*norel -print0 | xargs -0 rm -rf
+
+release: reldir
+ -rm -f .prerel .lastrel
+ cp .version .lastrel
+ tar cvvf - autofs-$(RELEASE) | gzip -9 > autofs-$(RELEASE).tar.gz
+
+since:
+ mv -f NEWS NEWS.old
+ echo 'Since autofs-$(RELEASE):' > NEWS
+ echo 'Since autofs-$(RELEASE):' | sed -e 's/./-/g' >> NEWS
+ echo '' >> NEWS
+ cat NEWS.old >> NEWS
+
+newrelease: clean since
+ echo `cut -d. -f1-2 < .version`.`expr \`cut -d. -f3 < .version\` + 1` \
+ > .version
+
+newminorrelease: clean since
+ echo `cut -d. -f1 < .version`.`expr \`cut -d. -f2 < .version\` + 1`.0 \
+ > .version
+
+newmajorrelease: clean since
+ echo `expr \`cut -d. -f1 < .version\` + 1`.0.0 > .version
+
+-include Makefile.private