dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
dnl with or without modifications, as long as this notice is preserved.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
dnl with or without modifications, as long as this notice is preserved.
AC_REQUIRE([gl_USE_SYSTEM_EXTENSIONS])
dnl argp-parse.c depends on GNU getopt internals, therefore use GNU getopt
dnl always.
AC_REQUIRE([gl_USE_SYSTEM_EXTENSIONS])
dnl argp-parse.c depends on GNU getopt internals, therefore use GNU getopt
dnl always.
[Define to 1 to add extern declaration of program_invocation_name to argp.h])],
[#include <errno.h>])
AC_CHECK_DECL([program_invocation_short_name],
[Define to 1 to add extern declaration of program_invocation_name to argp.h])],
[#include <errno.h>])
AC_CHECK_DECL([program_invocation_short_name],
# are defined elsewhere. It is improbable that only one of them will
# be defined and other not, I prefer to stay on the safe side and to
# test each one separately.
# are defined elsewhere. It is improbable that only one of them will
# be defined and other not, I prefer to stay on the safe side and to
# test each one separately.
AC_TRY_LINK([#include <argp.h>],
[ program_invocation_name = "test"; ],
AC_TRY_LINK([#include <argp.h>],
[ program_invocation_name = "test"; ],
AC_TRY_LINK([#include <argp.h>],
[ program_invocation_short_name = "test"; ],
AC_TRY_LINK([#include <argp.h>],
[ program_invocation_short_name = "test"; ],