Generate the ChangeLog from commit logs.
[gnupg.git] / Makefile.am
1 # Makefile.am - main makefile for NewPG/GnuPG
2 #       Copyright (C) 2001, 2004 Free Software Foundation, Inc.
3 #
4 # This file is part of GnuPG.
5 #
6 # GnuPG is free software; you can redistribute it and/or modify
7 # it under the terms of the GNU General Public License as published by
8 # the Free Software Foundation; either version 3 of the License, or
9 # (at your option) any later version.
10 #
11 # GnuPG is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14 # GNU General Public License for more details.
15 #
16 # You should have received a copy of the GNU General Public License
17 # along with this program; if not, see <http://www.gnu.org/licenses/>.
18
19 ## Process this file with automake to produce Makefile.in
20
21 ACLOCAL_AMFLAGS = -I m4 -I gl/m4
22 AUTOMAKE_OPTIONS = dist-bzip2 no-dist-gzip
23 DISTCHECK_CONFIGURE_FLAGS = --enable-symcryptrun --enable-mailto --enable-gpgtar
24
25 EXTRA_DIST = scripts/config.rpath autogen.sh README.SVN              \
26              ChangeLog-2011 po/ChangeLog-2011 scripts/ChangeLog-2011
27
28 DISTCLEANFILES = g10defs.h
29
30 if BUILD_GPGSM
31 kbx = kbx
32 else
33 kbx =
34 endif
35
36
37 if BUILD_GPG
38 gpg = g10
39 keyserver = keyserver
40 else
41 gpg =
42 keyserver =
43 endif
44 if BUILD_GPGSM
45 sm = sm
46 else
47 sm =
48 endif
49 if BUILD_AGENT
50 agent = agent
51 else
52 agent =
53 endif
54 if BUILD_SCDAEMON
55 scd = scd
56 else
57 scd =
58 endif
59 if BUILD_TOOLS
60 tools = tools
61 else
62 tools =
63 endif
64 if BUILD_DOC
65 doc = doc
66 else
67 doc =
68 endif
69
70 if HAVE_W32_SYSTEM
71 tests =
72 else
73 tests = tests
74 endif
75
76 SUBDIRS = m4 gl include jnlib common ${kbx} \
77  ${gpg} ${keyserver} ${sm} ${agent} ${scd} ${tools} po ${doc} ${tests}
78
79 dist_doc_DATA = README
80
81
82 dist-hook: gen-ChangeLog
83         echo "$(VERSION)" > $(distdir)/VERSION
84
85
86 gen_start_date = 2011-12-01T06:00:00
87 .PHONY: gen-ChangeLog
88 gen-ChangeLog:
89         if test -d $(top_srcdir)/.git; then                             \
90           (cd $(top_srcdir) &&                                          \
91             ./scripts/gitlog-to-changelog                               \
92             --amend=scripts/git-log-fix                                 \
93             --since=$(gen_start_date) ) > $(distdir)/cl-t;              \
94           cat $(top_srcdir)/scripts/git-log-footer >> $(distdir)/cl-t;  \
95           rm -f $(distdir)/ChangeLog;                                   \
96           mv $(distdir)/cl-t $(distdir)/ChangeLog;                      \
97         fi
98
99
100 stowinstall:
101         $(MAKE) $(AM_MAKEFLAGS) install prefix=/usr/local/stow/gnupg
102
103