summaryrefslogtreecommitdiff
path: root/Make.rules
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org.ua>2009-03-07 16:14:07 +0200
committerSergey Poznyakoff <gray@gnu.org.ua>2009-03-07 16:24:34 +0200
commitfb45630880343afb95c43fcbbb6883119e4e961a (patch)
tree09a1589c29010a7d5532ba9c2864a6b57c5437ca /Make.rules
parent8109596484d8910dd790b96f362095ee9de9e617 (diff)
downloadpaxutils-fb45630880343afb95c43fcbbb6883119e4e961a.tar.gz
Migrate to Git
Diffstat (limited to 'Make.rules')
-rw-r--r--Make.rules69
1 files changed, 69 insertions, 0 deletions
diff --git a/Make.rules b/Make.rules
new file mode 100644
index 0000000..a1de301
--- /dev/null
+++ b/Make.rules
@@ -0,0 +1,69 @@
+# This file is part of GNU paxutils
+#
+# Copyright (c) 2009 Free Software Foundation, Inc.
+#
+# Written by Sergey Poznyakoff
+#
+# GNU Paxutils is free software; you can redistribute it and/or modify it
+# under the terms of the GNU General Public License as published by the
+# Free Software Foundation; either version 3, or (at your option) any later
+# version.
+#
+# GNU Paxutils is distributed in the hope that it will be useful, but
+# without any warranty; without even the implied warranty of
+# merchantability or fitness for a particular purpose. see the gnu general
+# public license for more details.
+#
+# You should have received a copy of the GNU General Public License along
+# with GNU Paxutils; if not, write to the Free Software Foundation, Inc.,
+# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
+# This file is part of GNU paxutils
+#
+# Copyright (c) 2009 Free Software Foundation, Inc.
+#
+# Written by Sergey Poznyakoff
+#
+# GNU Paxutils is free software; you can redistribute it and/or modify it
+# under the terms of the GNU General Public License as published by the
+# Free Software Foundation; either version 3, or (at your option) any later
+# version.
+#
+# GNU Paxutils is distributed in the hope that it will be useful, but
+# without any warranty; without even the implied warranty of
+# merchantability or fitness for a particular purpose. see the gnu general
+# public license for more details.
+#
+# You should have received a copy of the GNU General Public License along
+# with GNU Paxutils; if not, write to the Free Software Foundation, Inc.,
+# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+
+# Define the following variables in order to use the ChangeLog rule below:
+# prev_change_log [optional] Name of the previous ChangeLog file.
+# gen_start_date [optional] Start ChangeLog from this date.
+# changelog_dir [mandatory] Directory where to create ChangeLog
+
+.PHONY: ChangeLog
+ChangeLog:
+ if test -d .git; then \
+ cmd=$(top_srcdir)/build-aux/gitlog-to-changelog; \
+ if test -n "$(gen_start_date)"; then \
+ cmd="$$cmd --since=\"$(gen_start_date)\""; \
+ fi; \
+ $$cmd | \
+ sed '/<unknown>$$/d' | fmt -s > $(changelog_dir)/cl-t; \
+ if test -n "$(prev_change_log)" && test -f "$(prev_change_log)"; \
+ then \
+ echo "" >> $(changelog_dir)/cl-t; \
+ cat "$(prev_change_log)" | \
+ sed '/^Local Variables:/,/^End:/d' >> $(changelog_dir)/cl-t; \
+ fi; \
+ echo "Local Variables:" >> $(changelog_dir)/cl-t; \
+ echo "mode: change-log" >> $(changelog_dir)/cl-t; \
+ echo "version-control: never" >> $(changelog_dir)/cl-t; \
+ echo "buffer-read-only: t" >> $(changelog_dir)/cl-t; \
+ echo "End:" >> $(changelog_dir)/cl-t; \
+ rm -f $(changelog_dir)/ChangeLog; \
+ mv $(changelog_dir)/cl-t $(changelog_dir)/ChangeLog; \
+ fi
+