~p-ch-e/gnuhello/gnuhello

« back to all changes in this revision

Viewing changes to gnulib/m4/mbrtowc.m4

  • Committer: Reuben Thomas
  • Date: 2011-12-17 11:23:38 UTC
  • Revision ID: rrt@sc3d.org-20111217112338-kurwdy8nu69g3t6f
Update gnulib and convert .cvsignore to .bzrignore.

        * gnulib: Update.
        * .bzrignore: Add.
        * .cvsignore: Remove.
        * contrib/.cvsignore: Likewise.
        * doc/.cvsignore: Likewise.
        * man/.cvsignore: Likewise.
        * po/.cvsignore: Likewise.
        * src/.cvsignore: Likewise.
        * tests/.cvsignore: Likewise.
        * build/mkinstalldirs: Remove: no longer needed.
        * po: Update.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# mbrtowc.m4 serial 22
 
1
# mbrtowc.m4 serial 25
2
2
dnl Copyright (C) 2001-2002, 2004-2005, 2008-2011 Free Software Foundation,
3
3
dnl Inc.
4
4
dnl This file is free software; the Free Software Foundation
15
15
  AC_CHECK_FUNCS_ONCE([mbrtowc])
16
16
  if test $ac_cv_func_mbrtowc = no; then
17
17
    HAVE_MBRTOWC=0
 
18
    AC_CHECK_DECLS([mbrtowc],,, [[
 
19
/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
 
20
   <wchar.h>.
 
21
   BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
 
22
   included before <wchar.h>.  */
 
23
#include <stddef.h>
 
24
#include <stdio.h>
 
25
#include <time.h>
 
26
#include <wchar.h>
 
27
]])
 
28
    if test $ac_cv_have_decl_mbrtowc = yes; then
 
29
      dnl On Minix 3.1.8, the system's <wchar.h> declares mbrtowc() although
 
30
      dnl it does not have the function. Avoid a collision with gnulib's
 
31
      dnl replacement.
 
32
      REPLACE_MBRTOWC=1
 
33
    fi
18
34
  else
19
35
    if test $REPLACE_MBSTATE_T = 1; then
20
36
      REPLACE_MBRTOWC=1
53
69
      esac
54
70
    fi
55
71
  fi
56
 
  if test $HAVE_MBRTOWC = 0 || test $REPLACE_MBRTOWC = 1; then
57
 
    gl_REPLACE_WCHAR_H
58
 
    AC_LIBOBJ([mbrtowc])
59
 
    gl_PREREQ_MBRTOWC
60
 
  fi
61
72
])
62
73
 
63
74
dnl Test whether mbsinit() and mbrtowc() need to be overridden in a way that
88
99
  else
89
100
    REPLACE_MBSTATE_T=1
90
101
  fi
91
 
  if test $REPLACE_MBSTATE_T = 1; then
92
 
    gl_REPLACE_WCHAR_H
93
 
  fi
94
102
])
95
103
 
96
104
dnl Test whether mbrtowc puts the state into non-initial state when parsing an