1 ## Process this file with automake to create Makefile.in
3 AUTOMAKE_OPTIONS = gnits
6 ## We need `.' in SUBDIRS because we want `check' to build `.' before
9 # Matthew D. Langston <langston@SLAC.Stanford.EDU>
10 # Temporarily remove `.' from SUBDIRS because it is causing make to
11 # infinitely recurse, and I don't know why.
12 ## SUBDIRS = . m4 tests
15 bin_SCRIPTS = automake aclocal
16 info_TEXINFOS = automake.texi am-f77.texi
18 amfiles = clean-hdr.am clean-kr.am clean.am comp-vars.am compile.am \
19 data-clean.am data.am dejagnu.am depend.am depend2.am dist-vars.am \
20 footer.am header-vars.am header.am java-clean.am java.am kr-extra.am \
21 library.am libs-clean.am libs.am libtool.am lisp-clean.am lisp.am \
22 ltlib-clean.am ltlib.am ltlibrary.am mans-vars.am mans.am multilib.am \
23 program.am progs-clean.am progs.am remake-hdr.am remake.am scripts.am \
24 subdirs.am tags-clean.am tags.am texi-vers.am texinfos.am
26 pkgdata_DATA = COPYING INSTALL texinfo.tex ansi2knr.c ansi2knr.1 $(amfiles)
28 ## These must all be executable when installed.
29 pkgdata_SCRIPTS = config.guess config.sub install-sh mdate-sh missing \
30 mkinstalldirs elisp-comp ylwrap acinstall
32 EXTRA_DIST = acinstall $(pkgdata_DATA)
34 # The following requires a fixed version of the Emacs 19.30 etags.
35 ETAGS_ARGS = automake.in aclocal.in --lang=none \
36 --regex='/^@node[ \t]+\([^,]+\)/\1/' automake.texi
37 TAGS_DEPENDENCIES = automake.in aclocal.in automake.texi
39 ## `test -x' is not portable. So we use Perl instead. If Perl
40 ## doesn't exist, then this test is meaningless anyway.
42 for file in $(pkgdata_SCRIPTS); do \
43 $(PERL) -e "exit ! -x '$(pkgdatadir)/$$file';" || exit 1; \
46 ################################################################
48 ## Everything past here is useful to the maintainer, but probably not
52 # Run the test suite using Perl 4.
53 perl4-check: automake aclocal
54 @if $(SHELL) -c 'perl4.036 -v' > /dev/null 2>&1; then \
55 $(MAKE) PERL=perl4.036 check; \
58 # Some simple checks, and then ordinary check. These are only really
59 # guaranteed to work on my machine.
60 maintainer-check: automake aclocal
61 ## This check avoids accidental configure substitutions in the source.
62 ## There are exactly 8 lines that should be modified. This works out
63 ## to 24 lines of diffs.
64 @if test `diff $(srcdir)/automake.in automake | wc -l` -ne 24; then \
65 echo "found too many diffs between automake.in and automake"; 1>&2; \
66 diff -c $(srcdir)/automake.in automake; \
69 ## Syntax check with default Perl (on my machine, Perl 5).
70 $(PERL) -c -w automake
72 ## expect no instances of '${...}'. However, $${...} is ok, since that
73 ## is a shell construct, not a Makefile construct.
74 @if test `fgrep '$${' $(srcdir)/[a-z]*.am | fgrep -v '$$$$' | wc -l` -ne 0; then \
75 echo "found too many uses of '\$${'" 1>&2; \
78 ## Make sure all invocations of mkinstalldirs are correct.
79 @if test `fgrep 'mkinstalldirs' $(srcdir)/[a-z]*.am | fgrep -v '$$(mkinstalldirs)' | wc -l` -ne 0; then \
80 echo "found incorrect use of mkinstalldirs" 1>&2; \
83 ## Another syntax check, this time with Perl 4, if it exists.
84 @if $(SHELL) -c 'perl4.036 -v' >/dev/null 2>&1; then \
85 perl4.036 -c -w automake; \
86 perl4.036 -c -w aclocal; \
88 ## We never want to use "undef", only "delete".
89 @if grep undef $(srcdir)/automake.in > /dev/null 2>&1; then \
90 echo "Found undef in automake.in; use delete instead" 1>&2; \
93 ## We never want split (/ /,...), only split (' ', ...).
94 @if fgrep 'split (/ /' $(srcdir)/automake.in > /dev/null 2>&1; then \
95 echo "Found bad split in automake.in" 1>&2; \
99 # Tag before making distribution. Also, don't make a distribution if
100 # checks fail. Also, make sure the NEWS file is up-to-date.
101 cvs-dist: maintainer-check perl4-check distcheck
102 @if sed 1q $(srcdir)/NEWS | grep -e "$(VERSION)" > /dev/null; then :; else \
103 echo "NEWS not updated; not releasing" 1>&2; \
106 cvs -q tag `echo "Release-$(VERSION)" | sed 's/\./-/g'`
110 thisver=`echo "Release-$(VERSION)" | sed 's/\./-/g'`; \
111 if test -z "$$OLDVERSION"; then \
112 prevno=`echo "$(VERSION)" - 0.01 | bc | sed 's/^\./0./'`; \
113 else prevno="$$OLDVERSION"; fi; \
114 prevver=Release-`echo $$prevno | sed 's/\./-/g'`; \
115 cvs -f rdiff -c -r $$prevver -r $$thisver $(PACKAGE) \
116 > $(PACKAGE)-$$prevno-$(VERSION).diff
118 ## Check our path lengths.
121 ## FIXME there's got to be a better way! pathchk should take the list
122 ## of files on stdin, at least.
123 find . -print | xargs pathchk -p); \
128 ## Just get the .am files into TAGS. We don't really care too much if
129 ## any interesting tags show up.
130 ETAGS_ARGS = $(amfiles)
131 TAGS_DEPENDENCIES = $(ETAGS_ARGS)