diff options
Diffstat (limited to 'gl/m4/vasnprintf.m4')
-rw-r--r-- | gl/m4/vasnprintf.m4 | 24 |
1 files changed, 20 insertions, 4 deletions
diff --git a/gl/m4/vasnprintf.m4 b/gl/m4/vasnprintf.m4 index 9e839d2..3a1d1e0 100644 --- a/gl/m4/vasnprintf.m4 +++ b/gl/m4/vasnprintf.m4 | |||
@@ -1,4 +1,4 @@ | |||
1 | # vasnprintf.m4 serial 26 | 1 | # vasnprintf.m4 serial 29 |
2 | dnl Copyright (C) 2002-2004, 2006-2009 Free Software Foundation, Inc. | 2 | dnl Copyright (C) 2002-2004, 2006-2009 Free Software Foundation, Inc. |
3 | dnl This file is free software; the Free Software Foundation | 3 | dnl This file is free software; the Free Software Foundation |
4 | dnl gives unlimited permission to copy and/or distribute it, | 4 | dnl gives unlimited permission to copy and/or distribute it, |
@@ -52,13 +52,13 @@ AC_DEFUN([gl_PREREQ_PRINTF_PARSE], | |||
52 | ]) | 52 | ]) |
53 | 53 | ||
54 | # Prerequisites of lib/vasnprintf.c. | 54 | # Prerequisites of lib/vasnprintf.c. |
55 | AC_DEFUN([gl_PREREQ_VASNPRINTF], | 55 | AC_DEFUN_ONCE([gl_PREREQ_VASNPRINTF], |
56 | [ | 56 | [ |
57 | AC_REQUIRE([AC_FUNC_ALLOCA]) | 57 | AC_REQUIRE([AC_FUNC_ALLOCA]) |
58 | AC_REQUIRE([AC_TYPE_LONG_LONG_INT]) | 58 | AC_REQUIRE([AC_TYPE_LONG_LONG_INT]) |
59 | AC_REQUIRE([gt_TYPE_WCHAR_T]) | 59 | AC_REQUIRE([gt_TYPE_WCHAR_T]) |
60 | AC_REQUIRE([gt_TYPE_WINT_T]) | 60 | AC_REQUIRE([gt_TYPE_WINT_T]) |
61 | AC_CHECK_FUNCS([snprintf wcslen]) | 61 | AC_CHECK_FUNCS([snprintf strnlen wcslen wcsnlen mbrtowc wcrtomb]) |
62 | dnl Use the _snprintf function only if it is declared (because on NetBSD it | 62 | dnl Use the _snprintf function only if it is declared (because on NetBSD it |
63 | dnl is defined as a weak alias of snprintf; we prefer to use the latter). | 63 | dnl is defined as a weak alias of snprintf; we prefer to use the latter). |
64 | AC_CHECK_DECLS([_snprintf], , , [#include <stdio.h>]) | 64 | AC_CHECK_DECLS([_snprintf], , , [#include <stdio.h>]) |
@@ -66,7 +66,7 @@ AC_DEFUN([gl_PREREQ_VASNPRINTF], | |||
66 | 66 | ||
67 | # Extra prerequisites of lib/vasnprintf.c for supporting 'long double' | 67 | # Extra prerequisites of lib/vasnprintf.c for supporting 'long double' |
68 | # arguments. | 68 | # arguments. |
69 | AC_DEFUN([gl_PREREQ_VASNPRINTF_LONG_DOUBLE], | 69 | AC_DEFUN_ONCE([gl_PREREQ_VASNPRINTF_LONG_DOUBLE], |
70 | [ | 70 | [ |
71 | AC_REQUIRE([gl_PRINTF_LONG_DOUBLE]) | 71 | AC_REQUIRE([gl_PRINTF_LONG_DOUBLE]) |
72 | case "$gl_cv_func_printf_long_double" in | 72 | case "$gl_cv_func_printf_long_double" in |
@@ -150,6 +150,21 @@ AC_DEFUN([gl_PREREQ_VASNPRINTF_DIRECTIVE_F], | |||
150 | esac | 150 | esac |
151 | ]) | 151 | ]) |
152 | 152 | ||
153 | # Extra prerequisites of lib/vasnprintf.c for supporting the 'ls' directive. | ||
154 | AC_DEFUN([gl_PREREQ_VASNPRINTF_DIRECTIVE_LS], | ||
155 | [ | ||
156 | AC_REQUIRE([gl_PRINTF_DIRECTIVE_LS]) | ||
157 | case "$gl_cv_func_printf_directive_ls" in | ||
158 | *yes) | ||
159 | ;; | ||
160 | *) | ||
161 | AC_DEFINE([NEED_PRINTF_DIRECTIVE_LS], [1], | ||
162 | [Define if the vasnprintf implementation needs special code for | ||
163 | the 'ls' directive.]) | ||
164 | ;; | ||
165 | esac | ||
166 | ]) | ||
167 | |||
153 | # Extra prerequisites of lib/vasnprintf.c for supporting the ' flag. | 168 | # Extra prerequisites of lib/vasnprintf.c for supporting the ' flag. |
154 | AC_DEFUN([gl_PREREQ_VASNPRINTF_FLAG_GROUPING], | 169 | AC_DEFUN([gl_PREREQ_VASNPRINTF_FLAG_GROUPING], |
155 | [ | 170 | [ |
@@ -247,6 +262,7 @@ AC_DEFUN([gl_PREREQ_VASNPRINTF_WITH_EXTRAS], | |||
247 | gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE | 262 | gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE |
248 | gl_PREREQ_VASNPRINTF_DIRECTIVE_A | 263 | gl_PREREQ_VASNPRINTF_DIRECTIVE_A |
249 | gl_PREREQ_VASNPRINTF_DIRECTIVE_F | 264 | gl_PREREQ_VASNPRINTF_DIRECTIVE_F |
265 | gl_PREREQ_VASNPRINTF_DIRECTIVE_LS | ||
250 | gl_PREREQ_VASNPRINTF_FLAG_GROUPING | 266 | gl_PREREQ_VASNPRINTF_FLAG_GROUPING |
251 | gl_PREREQ_VASNPRINTF_FLAG_LEFTADJUST | 267 | gl_PREREQ_VASNPRINTF_FLAG_LEFTADJUST |
252 | gl_PREREQ_VASNPRINTF_FLAG_ZERO | 268 | gl_PREREQ_VASNPRINTF_FLAG_ZERO |