Mercurial > emacs
annotate lispintro/aclocal.m4 @ 80025:f162659514ca
Comment changes.
author | Richard M. Stallman <rms@gnu.org> |
---|---|
date | Mon, 04 Feb 2008 16:54:05 +0000 |
parents | 6d19c76d81c5 |
children |
rev | line source |
---|---|
41418 | 1 dnl aclocal.m4 generated automatically by aclocal 1.4-p4 |
2 | |
75250
6d19c76d81c5
Update copyright for years from Emacs 21 to present (mainly adding
Glenn Morris <rgm@gnu.org>
parents:
68640
diff
changeset
|
3 dnl Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2001, 2002, 2003, |
6d19c76d81c5
Update copyright for years from Emacs 21 to present (mainly adding
Glenn Morris <rgm@gnu.org>
parents:
68640
diff
changeset
|
4 dnl 2004, 2005, 2006, 2007 Free Software Foundation, Inc. |
41418 | 5 dnl This file is free software; the Free Software Foundation |
6 dnl gives unlimited permission to copy and/or distribute it, | |
7 dnl with or without modifications, as long as this notice is preserved. | |
8 | |
9 dnl This program is distributed in the hope that it will be useful, | |
10 dnl but WITHOUT ANY WARRANTY, to the extent permitted by law; without | |
11 dnl even the implied warranty of MERCHANTABILITY or FITNESS FOR A | |
12 dnl PARTICULAR PURPOSE. | |
13 | |
14 # Do all the work for Automake. This macro actually does too much -- | |
15 # some checks are only needed if your package does certain things. | |
16 # But this isn't really a big deal. | |
17 | |
18 # serial 1 | |
19 | |
20 dnl Usage: | |
21 dnl AM_INIT_AUTOMAKE(package,version, [no-define]) | |
22 | |
23 AC_DEFUN(AM_INIT_AUTOMAKE, | |
24 [AC_REQUIRE([AC_PROG_INSTALL]) | |
25 PACKAGE=[$1] | |
26 AC_SUBST(PACKAGE) | |
27 VERSION=[$2] | |
28 AC_SUBST(VERSION) | |
29 dnl test to see if srcdir already configured | |
30 if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then | |
31 AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) | |
32 fi | |
33 ifelse([$3],, | |
34 AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package]) | |
35 AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])) | |
36 AC_REQUIRE([AM_SANITY_CHECK]) | |
37 AC_REQUIRE([AC_ARG_PROGRAM]) | |
38 dnl FIXME This is truly gross. | |
39 missing_dir=`cd $ac_aux_dir && pwd` | |
40 AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir) | |
41 AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir) | |
42 AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir) | |
43 AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir) | |
44 AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir) | |
45 AC_REQUIRE([AC_PROG_MAKE_SET])]) | |
46 | |
47 # | |
48 # Check to make sure that the build environment is sane. | |
49 # | |
50 | |
51 AC_DEFUN(AM_SANITY_CHECK, | |
52 [AC_MSG_CHECKING([whether build environment is sane]) | |
53 # Just in case | |
54 sleep 1 | |
55 echo timestamp > conftestfile | |
56 # Do `set' in a subshell so we don't clobber the current shell's | |
57 # arguments. Must try -L first in case configure is actually a | |
58 # symlink; some systems play weird games with the mod time of symlinks | |
59 # (eg FreeBSD returns the mod time of the symlink's containing | |
60 # directory). | |
61 if ( | |
62 set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null` | |
63 if test "[$]*" = "X"; then | |
64 # -L didn't work. | |
65 set X `ls -t $srcdir/configure conftestfile` | |
66 fi | |
67 if test "[$]*" != "X $srcdir/configure conftestfile" \ | |
68 && test "[$]*" != "X conftestfile $srcdir/configure"; then | |
69 | |
70 # If neither matched, then we have a broken ls. This can happen | |
71 # if, for instance, CONFIG_SHELL is bash and it inherits a | |
72 # broken ls alias from the environment. This has actually | |
73 # happened. Such a system could not be considered "sane". | |
74 AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken | |
75 alias in your environment]) | |
76 fi | |
77 | |
78 test "[$]2" = conftestfile | |
79 ) | |
80 then | |
81 # Ok. | |
82 : | |
83 else | |
84 AC_MSG_ERROR([newly created file is older than distributed files! | |
85 Check your system clock]) | |
86 fi | |
87 rm -f conftest* | |
88 AC_MSG_RESULT(yes)]) | |
89 | |
90 dnl AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY) | |
91 dnl The program must properly implement --version. | |
92 AC_DEFUN(AM_MISSING_PROG, | |
93 [AC_MSG_CHECKING(for working $2) | |
94 # Run test in a subshell; some versions of sh will print an error if | |
95 # an executable is not found, even if stderr is redirected. | |
96 # Redirect stdin to placate older versions of autoconf. Sigh. | |
97 if ($2 --version) < /dev/null > /dev/null 2>&1; then | |
98 $1=$2 | |
99 AC_MSG_RESULT(found) | |
100 else | |
101 $1="$3/missing $2" | |
102 AC_MSG_RESULT(missing) | |
103 fi | |
104 AC_SUBST($1)]) | |
105 |