X-Git-Url: https://diplodocus.org/git/nmh/blobdiff_plain/7e5bac1a416e400bd3c8941b1c312577f2d9e9e4..aaf31d46368bcf63f7ae4b0019ef09d098f98491:/Makefile.am diff --git a/Makefile.am b/Makefile.am index 9d10a037..cd3c886c 100644 --- a/Makefile.am +++ b/Makefile.am @@ -36,13 +36,23 @@ auxexecdir = @libdir@ CLEANFILES = config/version.c sbr/sigmsg.h etc/mts.conf etc/sendfiles \ etc/mhn.defaults man/man.sed $(man_MANS) clean-local: - @rm -rf RPM + @rm -rf RPM a.out.DSYM uip/a.out.DSYM ## ## Stuff that should be cleaned via "make maintainer-clean" ## MAINTAINERCLEANFILES = cscope.files cscope.out +## +## And our own superclean, to get everything left by maintainer-clean. +## +SUPERCLEANFILES = ChangeLog Makefile.in aclocal.m4 compile config.guess \ + config.h.in config.h.in~ config.sub configure depcomp \ + install-sh missing ylwrap nmh-*.tar.gz +superclean: maintainer-clean + @rm -f $(SUPERCLEANFILES) +.PHONY: superclean + ## ## Files that need to be built before everything else ## @@ -474,6 +484,15 @@ man/man.sed: Makefile .man.$(manext8): $(SED) -f man/man.sed $< > $@ +## Don't include commit hashes in ChangeLog. +ChangeLog: + @[ -d .git ] && git --no-pager log --abbrev-commit | \ + egrep -v '^commit [0-9a-f]+$$' > $@ || true +## Make ChangeLog phony so it will always get regenerated. But don't +## fail if we don't have a git repository in order to allow +## regeneration of distribution archive or RPM. +.PHONY: ChangeLog + ## ## Our RPM build target ## @@ -487,6 +506,7 @@ rpm: dist @rpmbuild --define '_topdir $(rpmdir)' \ --define '_tmppath %{_topdir}/TMP' \ -ba $(rpmdir)/SPECS/nmh.spec +.PHONY: rpm ## ## A target to build information needed by cscope