diff options
author | Bruno Haible <bruno@clisp.org> | 2008-09-27 19:14:53 +0200 |
---|---|---|
committer | Bruno Haible <bruno@clisp.org> | 2008-09-27 19:14:53 +0200 |
commit | 4640ec2f862cf1e3109270db86668f0b8e9ee710 (patch) | |
tree | 6dd41f7066a1fcdecc685b0f5ed1e7cbab065566 | |
parent | d62d8d02e05ea9688cc1c5c83c80c7c9c084ea9a (diff) | |
download | gnulib-4640ec2f862cf1e3109270db86668f0b8e9ee710.tar.gz |
Avoid assigning ICONV_H in two different files. Fixes a bug.
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | m4/iconv_h.m4 | 14 | ||||
-rw-r--r-- | m4/iconv_open.m4 | 6 |
3 files changed, 19 insertions, 7 deletions
@@ -1,5 +1,11 @@ 2008-09-27 Bruno Haible <bruno@clisp.org> + * m4/iconv_h.m4 (gl_REPLACE_ICONV_H): New macro. + (gl_ICONV_H_DEFAULTS): Initialize ICONV_H here... + (gl_ICONV_H): Not here. + * m4/iconv_open.m4 (gl_REPLACE_ICONV_OPEN): Invoke gl_REPLACE_ICONV_H + instead of assigning ICONV_H directly. + * m4/wchar.m4 (gl_REPLACE_WCHAR_H): New macro. * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Invoke it instead of assigning WCHAR_H directly. diff --git a/m4/iconv_h.m4 b/m4/iconv_h.m4 index 38f22900d1..bc05b05517 100644 --- a/m4/iconv_h.m4 +++ b/m4/iconv_h.m4 @@ -1,5 +1,5 @@ -# iconv_h.m4 serial 3 -dnl Copyright (C) 2007 Free Software Foundation, Inc. +# iconv_h.m4 serial 4 +dnl Copyright (C) 2007-2008 Free Software Foundation, Inc. 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. @@ -8,8 +8,13 @@ AC_DEFUN([gl_ICONV_H], [ AC_REQUIRE([gl_ICONV_H_DEFAULTS]) gl_CHECK_NEXT_HEADERS([iconv.h]) - ICONV_H= - AC_SUBST([ICONV_H]) +]) + +dnl Unconditionally enables the replacement of <iconv.h>. +AC_DEFUN([gl_REPLACE_ICONV_H], +[ + AC_REQUIRE([gl_ICONV_H_DEFAULTS]) + ICONV_H='iconv.h' ]) AC_DEFUN([gl_ICONV_MODULE_INDICATOR], @@ -25,4 +30,5 @@ AC_DEFUN([gl_ICONV_H_DEFAULTS], REPLACE_ICONV=0; AC_SUBST([REPLACE_ICONV]) REPLACE_ICONV_OPEN=0; AC_SUBST([REPLACE_ICONV_OPEN]) REPLACE_ICONV_UTF=0; AC_SUBST([REPLACE_ICONV_UTF]) + ICONV_H=''; AC_SUBST([ICONV_H]) ]) diff --git a/m4/iconv_open.m4 b/m4/iconv_open.m4 index e0bb0c36a1..d14da72a2a 100644 --- a/m4/iconv_open.m4 +++ b/m4/iconv_open.m4 @@ -1,5 +1,5 @@ -# iconv_open.m4 serial 3 -dnl Copyright (C) 2007 Free Software Foundation, Inc. +# iconv_open.m4 serial 4 +dnl Copyright (C) 2007-2008 Free Software Foundation, Inc. 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. @@ -38,9 +38,9 @@ AC_DEFUN([gl_FUNC_ICONV_OPEN], AC_DEFUN([gl_REPLACE_ICONV_OPEN], [ + gl_REPLACE_ICONV_H REPLACE_ICONV_OPEN=1 AC_LIBOBJ([iconv_open]) - ICONV_H='iconv.h' ]) AC_DEFUN([gl_FUNC_ICONV_OPEN_UTF], |