maint: update copyright year
[autoconf.git] / Makefile.am
blobb34d97ee42f02c29d6eda974f762e9367e61bd00
1 # Make Autoconf.
3 # Copyright (C) 1999-2004, 2006-2011 Free Software Foundation, Inc.
5 # This program is free software: you can redistribute it and/or modify
6 # it under the terms of the GNU General Public License as published by
7 # the Free Software Foundation, either version 3 of the License, or
8 # (at your option) any later version.
10 # This program is distributed in the hope that it will be useful,
11 # but WITHOUT ANY WARRANTY; without even the implied warranty of
12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13 # GNU General Public License for more details.
15 # You should have received a copy of the GNU General Public License
16 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
18 # bin/ must be run first, as it builds executables needed for tests.
19 # autom4te uses autotest.m4f to generate `testsuite', so build tests last.
20 # Rules in man/ use scripts from both bin/ and tests/, so *it* goes last.
21 SUBDIRS = bin . lib doc tests man
23 ACLOCAL_AMFLAGS = -I m4
25 EXTRA_DIST = ChangeLog.0 ChangeLog.1 ChangeLog.2 \
26              BUGS COPYINGv3 COPYING.EXCEPTION \
27              GNUmakefile maint.mk cfg.mk \
28              build-aux/gendocs.sh \
29              build-aux/git-version-gen \
30              build-aux/announce-gen build-aux/gnupload \
31              .prev-version .version
33 ## --------- ##
34 ## INSTALL.  ##
35 ## --------- ##
37 AM_MAKEINFOFLAGS = --no-headers --no-validate --no-split
39 if MAKE_CASE_SENSITIVE
40 pkgdata_DATA = $(srcdir)/INSTALL
42 MAINTAINERCLEANFILES = $(srcdir)/INSTALL
43 $(srcdir)/INSTALL: $(top_srcdir)/doc/install.texi
44         $(MAKEINFO) $(AM_MAKEINFOFLAGS) $(MAKEINFOFLAGS) --plaintext -o $@ \
45           $(top_srcdir)/doc/install.texi
46 endif
49 # Version string management.  There are two files to be aware of:
50 # .tarball-version - present only in a distribution tarball, and not in
51 #   a checked-out repository.  Created with contents that were learned at
52 #   the last time autoconf was run, and used by git-version-gen.  Must not
53 #   be present in either $(srcdir) or $(builddir) for git-version-gen to
54 #   give accurate answers during normal development with a checked out tree,
55 #   but must be present in a tarball when there is no version control system.
56 #   Therefore, it cannot be used in any dependencies.  GNUmakefile has
57 #   hooks to force a reconfigure at distribution time to get the value
58 #   correct, without penalizing normal development with extra reconfigures.
59 # .version - present in a checked-out repository and in a distribution
60 #   tarball.  At least as current as the most recent .tarball-version
61 #   creation.  Usable in dependencies, particularly for files that don't
62 #   want to depend on config.h but do want to track version changes.
63 BUILT_SOURCES = $(top_srcdir)/.version
64 $(top_srcdir)/.version:
65         echo $(VERSION) > $@-t && mv $@-t $@
67 # Arrange so that .tarball-version appears only in distribution tarballs,
68 # never in a checked-out repository.
69 dist-hook:
70         echo $(VERSION) > $(distdir)/.tarball-version
72 # Arrange to remove the symlink to GNUmakefile in VPATH builds.
73 # TODO remove this once automake vs. AC_CONFIG_LINKS issue is fixed.
74 distclean-local:
75         if test x"$(VPATH)" != x ; then rm -f GNUmakefile ; fi
77 # Perl coverage statistics.
78 PERL_COVERAGE_DB = `pwd`/cover_db
79 PERL_COVERAGE_FLAGS = -MDevel::Cover=-db,$(PERL_COVERAGE_DB),-silent,on,-summary,off
80 PERL_COVER = cover
82 check-coverage-run: all
83         $(mkinstalldirs) $(PERL_COVERAGE_DB)
84         PERL5OPT="$(PERL_COVERAGE_FLAGS)"; export PERL5OPT; \
85         $(MAKE) $(AM_MAKEFLAGS) check
87 check-coverage-report:
88         @if test ! -d $(PERL_COVERAGE_DB); then \
89           echo "No coverage database found in \`$(PERL_COVERAGE_DB)'." >&2; \
90           echo "Please run \`make check-coverage' first" >&2; \
91           exit 1; \
92         fi
93         $(PERL_COVER) $(PERL_COVERAGE_DB) $(PERL_COVER_FLAGS)
95 # We don't use direct dependencies here because we'd like to be able
96 # to invoke the report even after interrupted check-coverage.
97 check-coverage: check-coverage-run
98         $(MAKE) $(AM_MAKEFLAGS) check-coverage-report
100 clean-local: clean-coverage
101 clean-coverage:
102         rm -rf $(PERL_COVERAGE_DB)
104 .PHONY: check-coverage check-coverage-run check-coverage-report clean-coverage