Commit Graph

38 Commits

Author SHA1 Message Date
Akim Demaille
74eb7e6a10 * autoheader.m4 (autoheader::AC_CHECK_HEADERS_DIRENT): Renamed as
(autoheader::_AC_CHECK_HEADERS_DIRENT): to cope with the new name
of the autoconf:: macro.
Fixes autoconf/119, reported by Raja R Harinath.
2000-03-08 18:38:53 +00:00
Akim Demaille
7e4260dccb Define HAVE_DECL_FOO both to 1 if found and 0 otherwise.
* acgeneral.m4 (AC_CHECK_DECLS): Define HAVE_DECL_FOO to 1 instead
of NEED_FOO_DECL if found.  Define to 0 if not found.
* autoheader.m4 (AC_CHECK_DECLS): Template HAVE_DECL_FOO.
* tests/semantics.m4 (AC_CHECK_DECLS): Adjusted.
* doc/autoconf.texi (Generic Declarations): Adjusted.
2000-02-15 09:33:59 +00:00
Akim Demaille
c7bd04fb16 Keep `AC_CHECK_TYPE' backward compatibility and provide a proper
`AC_CHECK_TYPE',
Based on ideas from Paul Eggert and Alexandre Oliva.

* acgeneral.m4 (AC_CHECK_TYPE_INTERNAL): Renamed as
(_AC_CHECK_TYPE_NEW): this.
(AC_CHECK_TYPES): Adjusted.
(AC_CHECK_TYPE): Renamed as
(_AC_CHECK_TYPE_OLD): This.  Adjusted to _AC_CHECK_TYPE_NEW.
No longer support extra includes, stick to 2.13's interface.
(_AC_CHECK_TYPE_BUILTIN_P): New macro.
(AC_CHECK_TYPE): New macro.
* autoheader.m4 (autoheader::AC_CHECK_TYPE): Renamed as...
(autoheader::_AC_CHECK_TYPE_OLD): this.
* tests/atspecific.m4 (TEST_MACRO): Skip /^_AC_/ macros.
* tests/semantics.m4: Test the choices of AC_CHECK_TYPE (wrt _NEW
or _OLD implemenation).
* doc/autoconf.texi (Generic Types): Reorganized.  Explain
everything about AC_CHECK_TYPE and Co.
2000-02-10 10:24:10 +00:00
Akim Demaille
d6ef78697d AC_CHECK_FILES has never worked properly.
* acgeneral.m4 (AC_CHECK_FILE): Use AC_CACHE_CHECK.
* autoheader.m4 (AC_CHECK_FILES): AH-define.
* tests/semantics.m4: Test AC_CHECK_FILES.
* tests/atspecific.m4 (TEST_MACRO): Don't.
2000-02-10 09:40:55 +00:00
Akim Demaille
b54d44e0c3 Open the access to AH_ to users.
* autoheader.m4 (autoheader::AH_DEFUN): New macro.
* tests/tools.m4: New file, in charge of testing the scripts.
All the dependencies adapted.
* tests/actest.m4 (autoheader::AC_TATOOINE): New macro, used while
testing autoheader.
* tests/atspecific.m4: Create config.hin instead of config.h.in.
2000-02-08 13:54:48 +00:00
Akim Demaille
c7eb9bd99e Revamp the autoupdate/AC_OBSOLETE chain. All the details are
given in the prologue of acobsolete.m4.

* acgeneral.m4 (Prologue): Enter the `autoconf' name space.
(AU_DEFUN): New macro.

* autoupdate.m4: New file.
Disable the name spaces `autoconf', and `libm4'.  Disable libm4.
* Makefile.am: Tuned to support the changes above.

* autoupdate.sh: Model after autoconf.sh.
Can run on several files at once (for instance m4/*.m4).
Don't touch files that are up to date.
Run m4 on autoupdate.m4f instead of playing with sed.


Use AU_DEFUN.

* acgeneral.m4 (AC_LINK_FILES, AC_ENABLE, AC_WITH): Use AU_DEFUN,
remove the call to AC_OBSOLETE.
* acspecific.m4 (AC_CYGWIN32): Likewise.
* acoldnames.m4: Replaced all the definitions via `define' or
`AC_DEFUN' to use `AU_DEFUN'.
2000-02-08 13:25:49 +00:00
Akim Demaille
5ea4b5387a Clean up some m4 files.
* acoldnames.m4: Use `#', not `dnl'.
Don't spread `dnl' everywhere, anyway, we are in a divert(-1).
* autoconf.m4: Likewise.
* autoheader.m4: Likewise.
2000-02-08 13:16:01 +00:00
Akim Demaille
723b26a3de Adapt autoheader to use libm4's namespaces.
* autoheader.m4 (AH_HOOK): Removed.
(AH_DEFUN): Define in the `autoheader' name space.
Use only AH_DEFUN to define macros in this file.
(epilogue): No longer run the `AH_HOOKS', enter the `autoheader'
name space.
2000-02-08 11:46:51 +00:00
Akim Demaille
9a9baf80c6 Use #' for comments instead of dnl'.
Better highlighting of the sections in the sources.

* acgeneral.m4: Formatting changes.
* acspecific.m4: Likewise.
* autoheader.m4: Likewise.
* acoldnames.m4: Likewise.
2000-02-07 18:03:54 +00:00
Akim Demaille
6b8dfc89ca Create libm4.m4.
* Makefile.am: Adjusted for libm4.m4.

* acgeneral.m4 (m4_errprint, m4_warn, m4_fatal, m4_prefix,
m4_eval, m4_shift, m4_format, m4_include_unique, m4_include,
m4_sinclude, m4_quote, m4_split, m4_join, m4_strip, m4_append,
m4_list_append, ifval, ifset, m4_default, m4_case, m4_match,
m4_foreach): Moved from here, to...
* libm4.m4: here.
* acgeneral.m4 (AC_WRAP): Moved from here, to...
* libm4.m4 (m4_wrap): here.  All callers changed.

* acgeneral.m4: Don't include acversion.m4.
* autoconf.m4: Include libm4.m4 and acversion.m4.
* autoheader.m4: Likewise.
2000-02-07 17:42:03 +00:00
Akim Demaille
00f447ee06 * acspecific.m4 (AC_C_INLINE): Proceed as for AC_C_CONST:
condition out the test case if __cpluscplus.
Don't document the autoheader template twice, one is enough.
* autoheader.m4 (AC_CONFIG_HEADER): don't hook on this guy, but
on...
(AC_CONFIG_HEADERS), since the former is defined on the latter.
2000-02-07 15:39:16 +00:00
Akim Demaille
3c2a8f9b09 Start a new series of tests which check the semantics.
* acgeneral.m4 (AC_CHECK_MEMBER): It is not smart to define
ac_Foo, and use AC_Foo.  Got rid of AC_Member_Aggregate and
AC_Member_Member which were complicating more than simplifying.
(AC_CHECK_DECLS): Use m4 lists.
(AC_CHECK_TYPES): A comma was missing.
* autoheader.m4: (AC_CHECK_DECLS): Use m4 lists.
* doc/autoconf.texi (Generic Declarations): AC_CHECK_DELCS uses m4
lists.
* tests/semantics.m4: New file.  Collection of semantical tests:
verify that the tests are positive and negative when appropriate.
Test AC_CHECK_MEMBERS, AC_CHECK_DECLS and AC_CHECK_TYPES.
2000-02-07 11:54:29 +00:00
Akim Demaille
ea044949a5 Hide AH_HOOK behind AH_DEFUN.
* autoheader.m4 (AH_DEFUN): New macro.  Combination of define and
AH_HOOK.
(AC_TRY_RUN, AC_DEFINE, AC_DEFINE_UNQUOTED, AC_CHECK_LIB,
AC_CHECK_HEADERS, AC_CHECK_HEADERS_DIRENT, AC_CHECK_DECLS,
AC_CHECK_FUNCS, AC_CHECK_SIZEOF, AC_PROG_LEX, AC_CHECK_MEMBERS,
AC_CHECK_TYPE, AC_FUNC_ALLOCA, AC_CHECK_TYPES, AC_C_CHAR_UNSIGNED,
AC_AIX, AC_F77_WRAPPERS, AC_CONFIG_HEADER): All the former calls
to define and AH_HOOK in autoheader.m4 are replaced by AH_DEFUN.
2000-02-04 13:37:47 +00:00
Akim Demaille
b9b4dc14d8 Check that the AC_DEFINEs from acspecific.m4 do have a template.
Fix the discovered bugs.

* tests/atgeneral.m4 (AT_CHECK): Don't just exit 1 when you want
to propagate the failure of a test: exit with the same exit
status, at least to preserve 77 (=ignore).
* tests/syntax.m4 (TEST_MACRO): Run also autoheader.  Don't run
this test on all the macros, some just cannot run without
arguments.
* acgeneral.m4 (AC_OUTPUT_CONFIG_STATUS): In the if egrep/fi for
#define templates, add a `:' to prevent syntax errors in
config.status when there are no AC_DEFINE performed.
* autoheader.m4 (AH_TEMPLATE): Don't use _AC_SH_QUOTE here, use it
in...
(AH_VERBATIM): here.  Now AH_C_UNSIGNED_CHAR is no longer failing
(formerly it would produce a non backslashed backquote, which
made sh choke).
2000-02-04 10:23:15 +00:00
Akim Demaille
ddfcae90fa 1999-11-10 Akim Demaille <akim@epita.fr>
* autoconf.sh: Formatting changes.
	Removed development junk.
	* acspecific.m4: Formatting changes.
	* autoconf.m4: Likewise.
	* autoheader.m4: Likewise.
2000-01-29 11:37:48 +00:00
Akim Demaille
6b39479736 1999-11-01 Akim Demaille <akim@epita.fr>
* autoheader.m4 (AH_FUNC_ALLOCA, AH_C_CHAR_UNSIGNED, AH_AIX):
	Don't leave `[]dnl' in pseudo #-comment (actually CPP directives).
2000-01-28 11:00:16 +00:00
Akim Demaille
13527a7b56 1999-11-01 Akim Demaille <akim@epita.fr>
Fix a bit of the brokenness of AC_CHECK_TYPE.

	* acgeneral.m4 (AC_CHECK_TYPE_INTERNAL): New macro, inspired from
 	the former AC_CHECK_TYPE.  This macro is exactly the one that
 	ought to be named AC_CHECK_TYPE: it just checks, and executes user
 	actions.  In the future, this macro ought to be renamed
 	AC_CHECK_TYPE.
	There is a big difference with the former AC_CHECK_TYPE: instead
 	of grepping in the headers, it tries to compile a variable
 	declaration.  This is both safer, slower, and better, since now we
 	can check for compiler types (e.g., unsigned long long).
	(AC_CHECK_TYPES): The looping and AC_DEFINEing version of the
 	previous macro.  Uses m4 loops.
	(AC_CHECK_TYPE): Reimplemented on top of AC_CHECK_TYPE_INTERNAL.
  	* autoheader.m4 (AH_CHECK_TYPE, AH_CHECK_TYPES): New macros,
 	hooked.
	* autoconf.texi (@ovar): New macro, for optional variables.
	(Generic Typedefs): Document AC_CHECK_TYPES.
	* autoheader.texi: (AH_CHECK_TYPE, AH_CHECK_TYPES): New macros.
	(Epilogue): Hooks them.
2000-01-28 10:41:47 +00:00
Akim Demaille
0c1771941f 1999-10-31 Akim Demaille <akim@epita.fr>
* autoheader.m4 (AH_TEMPLATE): Quote $2 once, now _AC_SH_QUOTE
	behaves properly.
2000-01-14 18:07:57 +00:00
Akim Demaille
ecb19983da 1999-10-31 Akim Demaille <akim@epita.fr>
Perform a better checking for missing templates in autoheader.

	* autoheader.m4 (AH_HOOK): When hook AC_FOO on AH_FOO, define the
	new AC_FOO to be the expansion of both AH_FOO *and* AC_FOO.  See
	its definition for the motivations.

	* autoheader.m4 (AH_FUNC_ALLOCA): Remove the now useless
	additional templates.
2000-01-10 10:06:51 +00:00
Akim Demaille
c61438fda5 1999-10-31 Akim Demaille <akim@epita.fr>
Fix a bug in templates of AC_CHECK_LIB.

	* autoheader.m4 (AH_CHECK_LIB): Template HAVE_LIBFOO, not
 	HAVE_FOO.
1999-12-21 13:44:54 +00:00
Akim Demaille
bfb9905e93 1999-10-31 Akim Demaille <akim@epita.fr>
* autoconf.m4: Insert -*- Autoconf -*-.
	* acgeneral.m4: Likewise.
	* acspecific.m4: Likewise.
	* acoldnames.m4: Likewise.
1999-12-20 15:54:30 +00:00
Akim Demaille
ed0f9a6d4e 1999-10-31 Akim Demaille <akim@epita.fr>
Rename the family AC_NEED_DECL as AC_CHECK: it is more uniform,
	but keep defining NEED_FOO_DECL when `foo' is not declared.  Files
	not using Autoconf behave better when declarations lacks than when
	they are wrong.  So the unset position should off, hence #if NEEDS
	instead of #if !HAVE (which is triggered when HAVE is not set).

	* acgeneral.m4 (AC_NEED_DECL): Renamed as...
	(AC_CHECK_DECL): This.  Make sure the arguments are the usual
	IF-FOUND, IF-NOT-FOUND.
	(AC_NEED_DECLS, AC_CHECK_DECLS): Likewise.
	* autoconf.texi (Generic Declarations): Document the changes
 	aforementioned.
	* autoheader.m4 (AH_NEED_DECLS): Renamed as
	(AH_CHECK_DECLS): This.
	(AH_HOOKS): Hook AH_CHECK_DECLS on AC_CHECK_DECLS instead of
	_NEED_.
1999-12-20 13:40:18 +00:00
Akim Demaille
7d74895243 1999-10-31 Akim Demaille <akim@epita.fr>
Revamp the handling of the arguments of config.status: instead of
	looping over config_files etc. to recognize the file names, use
	the case which handles the options.
	Suggested by Alexandre Oliva.

	* acgeneral.m4 (ifset): Renamed as...
	(ifval): This.  All callers changed.
	(ifset): New macro, which tests if a macro is set to a non empty
	value.

	* acgeneral.m4: Initialize growing lists and strings to empty, to
	ease the tests.
	(AC_CONFIG_HEADER): Quote AC_LIST_HEADERS in the define, to handle
	the case AC_LIST_HEADERS is initialized.

	* acgeneral.m4: (AC_OUTPUT_CONFIG_STATUS): New macro, pulled out
	from...
	(AC_OUTPUT): Instead of using $1, $2 and $3, pass them to the
	official macros (AC_CONFIG_FILES, AC_OUTPUT_COMMANTS).
	Call AC_OUTPUT_CONFIG_STATUS.
	(option handling): Use the case-esac to recognize arguments.
	(AC_OUTPUT_COMMANDS): Fix the missing fi;done.
1999-12-20 13:37:12 +00:00
Akim Demaille
0716d22ed3 1999-10-31 Akim Demaille <akim@epita.fr>
Provide the m4 infrastructure for defining AH_ hooks.

	* autoheader.m4 (AH_HOOK): New macro.
	Hook all the AC_ macros to their AH_siblings in AH_HOOKS.
	Run AH_HOOKS.

	* acgeneral.m4 (m4_append): New macro.
	(m4_list_append, m4_list_add): Removed.
1999-12-20 12:08:01 +00:00
Akim Demaille
71c0040e3b 1999-10-31 Akim Demaille <akim@epita.fr>
* acspecific.m4 (AC_CHECK_MEMBER, AC_CHECK_MEMBERS): New macros.
	* autoheader.m4 (AH_CHECK_MEMBERS): New macro.
	(epilogue): Hook AH_CHECK_MEMBERS on AC_CHECK_MEMBERS.
1999-12-20 12:01:55 +00:00
Ben Elliston
dc08b45c63 1999-10-31 Akim Demaille <akim@epita.fr>
* autoheader.m4 (AC_FUNC_ALLOCA): Rename from this ...
	(AH_FUNC_ALLOCA): ... to this.  Includes all the needed templates.
	(AC_C_CHAR_UNSIGNED): Rename from this ...
	(AH_C_CHAR_UNSIGNED): ... to this.
1999-10-31 02:37:40 +00:00
Ben Elliston
7e49021235 * Merged from the experimental branch. 1999-10-30 14:17:20 +00:00
Ben Elliston
c22c6d450c 1999-09-04 Jeremy Elson <jelson@circlemud.org>
* autoheader.m4 (AC_CHECK_HEADER): Define.
1999-09-04 07:05:34 +00:00
Ben Elliston
3a9aeb1812 1999-04-11 Pavel Roskin <pavel_roskin@geocities.com>
* autoheader.m4: Do not complain about using AC_TRY_RUN without a
	cross-compilation action--only autoconf should do this.
1999-04-11 00:39:32 +00:00
Ben Elliston
b8b5a1519f Back out Pavel Roskin's autoheader patch. It's broken. 1999-04-10 21:50:49 +00:00
Ben Elliston
3c7c99978a 1999-02-10 Pavel Roskin <pavel_roskin@geocities.com>
* autoheader.m4: Do not complain about using AC_TRY_RUN without a
	cross-compilation action--only autoconf should do this.
1999-04-10 21:10:58 +00:00
Ben Elliston
013957a4ce Sun Oct 4 21:57:20 1998 Tom Tromey <tromey@cygnus.com>
* autoconf.texi (Defining Symbols): Documented third argument to
	AC_DEFINE.
	* autoheader.m4 (AC_DEFINE_UNQUOTED): Generate `verbatim'
	assignment if third argument given.
	(AC_DEFINE): Likewise.
	* acgeneral.m4 (AC_DEFINE): Handle case where $# is 3.
	(AC_DEFINE_UNQUOTED): Likewise.
	* autoheader.sh: Echo $verbatim if not empty.
1998-10-09 07:44:10 +00:00
David MacKenzie
148902c9c6 update street address 1996-06-12 17:55:25 +00:00
David MacKenzie
c77ff9f7d2 more bug fixes 1995-11-22 17:42:19 +00:00
David MacKenzie
55af85f0bf various tweaks 1995-07-26 05:30:39 +00:00
David MacKenzie
4b515ebbeb misc little fixes 1994-09-09 20:13:30 +00:00
David MacKenzie
01cddb594a new macros to reduce kludges 1994-09-08 20:42:23 +00:00
David MacKenzie
d85c54a75f Initial revision 1994-08-30 20:24:28 +00:00