annotate m4/argp.m4 @ 285:9010796c6253 2.3 2.3.1

Generated manual for distribution
author lost
date Fri, 24 Apr 2009 22:36:09 +0000
parents 2cb097e760a5
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
283
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
1 # argp.m4 serial 8
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
2 dnl Copyright (C) 2003-2007 Free Software Foundation, Inc.
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
3 dnl This file is free software; the Free Software Foundation
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
4 dnl gives unlimited permission to copy and/or distribute it,
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
5 dnl with or without modifications, as long as this notice is preserved.
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
6
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
7 AC_DEFUN([gl_ARGP],
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
8 [
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
9 AC_REQUIRE([AC_C_INLINE])
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
10 AC_REQUIRE([AC_C_RESTRICT])
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
11 AC_REQUIRE([gl_USE_SYSTEM_EXTENSIONS])
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
12 dnl argp-parse.c depends on GNU getopt internals, therefore use GNU getopt
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
13 dnl always.
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
14 gl_GETOPT_SUBSTITUTE
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
15 dnl Note: gl_GETOPT_SUBSTITUTE does AC_LIBOBJ(getopt), AC_LIBOBJ(getopt1).
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
16
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
17 AC_CHECK_DECL([program_invocation_name],
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
18 [AC_DEFINE(HAVE_DECL_PROGRAM_INVOCATION_NAME, 1,
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
19 [Define if program_invocation_name is declared])],
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
20 [AC_DEFINE(GNULIB_PROGRAM_INVOCATION_NAME, 1,
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
21 [Define to 1 to add extern declaration of program_invocation_name to argp.h])],
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
22 [#include <errno.h>])
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
23 AC_CHECK_DECL([program_invocation_short_name],
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
24 [AC_DEFINE(HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME, 1,
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
25 [Define if program_invocation_short_name is declared])],
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
26 [AC_DEFINE(GNULIB_PROGRAM_INVOCATION_SHORT_NAME, 1,
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
27 [Define to 1 to add extern declaration of program_invocation_short_name to argp.h])],
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
28 [#include <errno.h>])
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
29
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
30 # Check if program_invocation_name and program_invocation_short_name
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
31 # are defined elsewhere. It is improbable that only one of them will
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
32 # be defined and other not, I prefer to stay on the safe side and to
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
33 # test each one separately.
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
34 AC_MSG_CHECKING(whether program_invocation_name is defined)
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
35 AC_TRY_LINK([#include <argp.h>],
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
36 [ program_invocation_name = "test"; ],
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
37 [ AC_DEFINE(HAVE_PROGRAM_INVOCATION_NAME,1,
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
38 [Define if program_invocation_name is defined])
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
39 AC_MSG_RESULT(yes)],
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
40 [ AC_MSG_RESULT(no)] )
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
41
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
42 AC_MSG_CHECKING(whether program_invocation_short_name is defined)
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
43 AC_TRY_LINK([#include <argp.h>],
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
44 [ program_invocation_short_name = "test"; ],
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
45 [ AC_DEFINE(HAVE_PROGRAM_INVOCATION_SHORT_NAME,1,
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
46 [Define if program_invocation_short_name is defined])
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
47 AC_MSG_RESULT(yes)],
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
48 [ AC_MSG_RESULT(no)] )
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
49
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
50 AC_CHECK_DECLS_ONCE([clearerr_unlocked])
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
51 AC_CHECK_DECLS_ONCE([feof_unlocked])
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
52 AC_CHECK_DECLS_ONCE([ferror_unlocked])
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
53 AC_CHECK_DECLS_ONCE([fflush_unlocked])
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
54 AC_CHECK_DECLS_ONCE([fgets_unlocked])
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
55 AC_CHECK_DECLS_ONCE([fputc_unlocked])
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
56 AC_CHECK_DECLS_ONCE([fputs_unlocked])
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
57 AC_CHECK_DECLS_ONCE([fread_unlocked])
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
58 AC_CHECK_DECLS_ONCE([fwrite_unlocked])
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
59 AC_CHECK_DECLS_ONCE([getc_unlocked])
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
60 AC_CHECK_DECLS_ONCE([getchar_unlocked])
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
61 AC_CHECK_DECLS_ONCE([putc_unlocked])
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
62 AC_CHECK_DECLS_ONCE([putchar_unlocked])
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
63 AC_CHECK_FUNCS_ONCE([flockfile funlockfile])
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
64 AC_CHECK_HEADERS_ONCE([features.h linewrap.h])
2cb097e760a5 Added various generated files in prep for release
lost
parents:
diff changeset
65 ])