configure.ac, lib/*, example/*.c, src/iso-read.c:

start to separate compiler/OS deficiencies into "portable.h"

configure.ac, lib/iso9660_fs.c:
  use AM_LANGINFO_CODESET rather than code in our ouwn langinfo.h and
  CODESET tests.
This commit is contained in:
rocky
2004-10-31 13:58:44 +00:00
parent 64f2ad383d
commit 465e0373ee
9 changed files with 78 additions and 37 deletions

View File

@@ -1,5 +1,5 @@
/*
$Id: iso9660_fs.c,v 1.40 2004/10/31 04:55:57 rocky Exp $
$Id: iso9660_fs.c,v 1.41 2004/10/31 13:58:44 rocky Exp $
Copyright (C) 2001 Herbert Valerio Riedel <hvr@gnu.org>
Copyright (C) 2003, 2004 Rocky Bernstein <rocky@panix.com>
@@ -35,7 +35,7 @@
# include <iconv.h>
#endif
#ifdef HAVE_LANGINFO_H
#ifdef HAVE_LANGINFO_CODESET
#include <langinfo.h>
#endif
@@ -51,7 +51,7 @@
#include <stdio.h>
static const char _rcsid[] = "$Id: iso9660_fs.c,v 1.40 2004/10/31 04:55:57 rocky Exp $";
static const char _rcsid[] = "$Id: iso9660_fs.c,v 1.41 2004/10/31 13:58:44 rocky Exp $";
/* Implementation of iso9660_t type */
struct _iso9660 {
@@ -146,7 +146,7 @@ static bool
ucs2be_to_locale(ICONV_CONST char *psz_ucs2be, size_t i_inlen,
char **p_psz_out, size_t i_outlen)
{
#if defined(HAVE_NL_LANGINFO) && defined(HAVE_LANGINFO_H)
#if defined(HAVE_LANGINFO_CODESET)
iconv_t ic = iconv_open(nl_langinfo(CODESET), "UCS-2BE");
#else
iconv_t ic = iconv_open("ASCII", "UCS-2BE");