summaryrefslogtreecommitdiff
path: root/m4
diff options
context:
space:
mode:
authorBruno Haible <bruno@clisp.org>2010-06-01 01:26:32 +0200
committerBruno Haible <bruno@clisp.org>2010-06-01 01:26:32 +0200
commit2988c8c21303fdadb3a9efe321870d96f6bdc668 (patch)
treeac14800a55b3e173c8ea4ac0a25c666b181e420f /m4
parentbf9c9b72edc4f0614fdb17c1ee33bf9ea4e42cfa (diff)
downloadgnulib-2988c8c21303fdadb3a9efe321870d96f6bdc668.tar.gz
Avoid expanding two macros in the wrong order.
Diffstat (limited to 'm4')
-rw-r--r--m4/libunistring-base.m45
-rw-r--r--m4/libunistring.m47
2 files changed, 9 insertions, 3 deletions
diff --git a/m4/libunistring-base.m4 b/m4/libunistring-base.m4
index 54aa521c7a..a36e5f4928 100644
--- a/m4/libunistring-base.m4
+++ b/m4/libunistring-base.m4
@@ -1,4 +1,4 @@
-# libunistring-base.m4 serial 2
+# libunistring-base.m4 serial 3
dnl Copyright (C) 2010 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@@ -66,6 +66,9 @@ dnl Miscellaneous preparations/initializations.
AC_DEFUN([gl_LIBUNISTRING_LIB_PREPARE],
[
+ dnl Ensure that HAVE_LIBUNISTRING is fully determined at this point.
+ m4_ifdef([gl_LIBUNISTRING], [AC_REQUIRE([gl_LIBUNISTRING])])
+
AC_REQUIRE([AC_PROG_AWK])
dnl Sed expressions to extract the parts of a version number.
diff --git a/m4/libunistring.m4 b/m4/libunistring.m4
index 7a10efec79..5e4e7d9eaa 100644
--- a/m4/libunistring.m4
+++ b/m4/libunistring.m4
@@ -1,4 +1,4 @@
-# libunistring.m4 serial 6
+# libunistring.m4 serial 7
dnl Copyright (C) 2009-2010 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@@ -12,7 +12,10 @@ dnl augments the CPPFLAGS variable, and #defines HAVE_LIBUNISTRING to 1.
dnl Otherwise, it sets and AC_SUBSTs HAVE_LIBUNISTRING=no and LIBUNISTRING and
dnl LTLIBUNISTRING to empty.
-AC_DEFUN([gl_LIBUNISTRING],
+dnl Define gl_LIBUNISTRING using AC_DEFUN_ONCE for Autoconf >= 2.64, in order
+dnl to avoid warnings like
+dnl "warning: AC_REQUIRE: `gl_LIBUNISTRING' was expanded before it was required".
+m4_version_prereq([2.64],[AC_DEFUN_ONCE],[AC_DEFUN])([gl_LIBUNISTRING],
[
AC_BEFORE([$0], [gl_LIBUNISTRING_LIBSOURCE])
AC_BEFORE([$0], [gl_LIBUNISTRING_LIBHEADER])