aboutsummaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org.ua>2005-10-03 14:14:16 +0000
committerSergey Poznyakoff <gray@gnu.org.ua>2005-10-03 14:14:16 +0000
commit2427d2e239133c2d9a05c41eaa4cc20ecfefbb99 (patch)
tree56247254c5a1792c6a04f9cbae5216bf2cfce436 /configure.ac
parent17e5f53b466851bc38dec08e9dc43d5f43ce5d9b (diff)
downloadcflow-2427d2e239133c2d9a05c41eaa4cc20ecfefbb99.tar.gz
cflow-2427d2e239133c2d9a05c41eaa4cc20ecfefbb99.tar.bz2
Make sure HAVE_DECL_PROGRAM_INVOCATION_NAME is 1.
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac9
1 files changed, 8 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac
index 6586e2c..ee97696 100644
--- a/configure.ac
+++ b/configure.ac
@@ -39,6 +39,13 @@ AC_CHECK_HEADERS([stdlib.h string.h unistd.h locale.h])
AC_FUNC_ERROR_AT_LINE
AC_CHECK_FUNCS([memmove memset strdup strerror strtol setlocale])
+# Dirty hack: make sure HAVE_DECL_PROGRAM_INVOCATION_NAME is defined
+# This must be done before gl_ARGP, which attempts
+# an AC_CHECK_DECLS([program_invocation_name), because autoconf machinery
+# gives preference to the first definition, in spite of what the comment
+# at autoconf/status.m4:574 sais
+AC_DEFINE([HAVE_DECL_PROGRAM_INVOCATION_NAME], 1)
+
cflow_GNULIB
MU_DEBUG_MODE
@@ -48,12 +55,12 @@ AH_TEMPLATE([PROGRAM_INVOCATION_NAME_DECLARED],
# This variable should have been set in m4/argp.m4
if test "$ac_cv_have_decl_program_invocation_name" = no; then
AC_LIBOBJ([pin])
- AC_DEFINE([HAVE_DECL_PROGRAM_INVOCATION_NAME],1)
AC_DEFINE_UNQUOTED([PROGRAM_INVOCATION_NAME_DECLARED],0)
else
AC_DEFINE_UNQUOTED([PROGRAM_INVOCATION_NAME_DECLARED],1)
fi
+
AH_BOTTOM([
#if !PROGRAM_INVOCATION_NAME_DECLARED
extern char *program_invocation_short_name;

Return to:

Send suggestions and report system problems to the System administrator.