Blame gettext-runtime/m4/codeset.m4

Packit 5b56b6
# codeset.m4 serial 5 (gettext-0.18.2)
Packit 5b56b6
dnl Copyright (C) 2000-2002, 2006, 2008-2014 Free Software Foundation, Inc.
Packit 5b56b6
dnl This file is free software; the Free Software Foundation
Packit 5b56b6
dnl gives unlimited permission to copy and/or distribute it,
Packit 5b56b6
dnl with or without modifications, as long as this notice is preserved.
Packit 5b56b6
Packit 5b56b6
dnl From Bruno Haible.
Packit 5b56b6
Packit 5b56b6
AC_DEFUN([AM_LANGINFO_CODESET],
Packit 5b56b6
[
Packit 5b56b6
  AC_CACHE_CHECK([for nl_langinfo and CODESET], [am_cv_langinfo_codeset],
Packit 5b56b6
    [AC_LINK_IFELSE(
Packit 5b56b6
       [AC_LANG_PROGRAM(
Packit 5b56b6
          [[#include <langinfo.h>]],
Packit 5b56b6
          [[char* cs = nl_langinfo(CODESET); return !cs;]])],
Packit 5b56b6
       [am_cv_langinfo_codeset=yes],
Packit 5b56b6
       [am_cv_langinfo_codeset=no])
Packit 5b56b6
    ])
Packit 5b56b6
  if test $am_cv_langinfo_codeset = yes; then
Packit 5b56b6
    AC_DEFINE([HAVE_LANGINFO_CODESET], [1],
Packit 5b56b6
      [Define if you have <langinfo.h> and nl_langinfo(CODESET).])
Packit 5b56b6
  fi
Packit 5b56b6
])