From: Adrian Bunk Date: Mon, 3 Feb 2003 13:57:15 +0000 (+0000) Subject: Fix for java/4269: X-Git-Tag: releases/gcc-3.4.0~8925 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=7d503466fb85d355e25d5b1aa06ad8f9818a07fa;p=thirdparty%2Fgcc.git Fix for java/4269: 2003-01-31 Adrian Bunk Fix for java/4269: * jv-scan.c: Use HAVE_LANGINFO_CODESET instead of HAVE_NL_LANGINFO to fix bootstrap on sparc-unknown-netbsdelf1.5. * jcf-parse.c: Likewise. From-SVN: r62310 --- diff --git a/gcc/java/ChangeLog b/gcc/java/ChangeLog index bb360c0afc05..3343824e4c8e 100644 --- a/gcc/java/ChangeLog +++ b/gcc/java/ChangeLog @@ -1,3 +1,11 @@ +2003-01-31 Adrian Bunk + + Fix for java/4269: + + * jv-scan.c: Use HAVE_LANGINFO_CODESET instead of HAVE_NL_LANGINFO + to fix bootstrap on sparc-unknown-netbsdelf1.5. + * jcf-parse.c: Likewise. + 2003-01-31 Mark Wielaard * gjavah.c (throwable_p): Allocate 1 more byte for string. diff --git a/gcc/java/jcf-parse.c b/gcc/java/jcf-parse.c index 20dc3ff9208e..ac4757ca20a2 100644 --- a/gcc/java/jcf-parse.c +++ b/gcc/java/jcf-parse.c @@ -47,7 +47,7 @@ The Free Software Foundation is independent of Sun Microsystems, Inc. */ #include #endif -#ifdef HAVE_NL_LANGINFO +#ifdef HAVE_LANGINFO_CODESET #include #endif @@ -802,7 +802,7 @@ parse_source_file_1 (tree file, FILE *finput) /* There's no point in trying to find the current encoding unless we are going to do something intelligent with it -- hence the test for iconv. */ -#if defined (HAVE_LOCALE_H) && defined (HAVE_ICONV) && defined (HAVE_NL_LANGINFO) +#if defined (HAVE_LOCALE_H) && defined (HAVE_ICONV) && defined (HAVE_LANGINFO_CODESET) setlocale (LC_CTYPE, ""); if (current_encoding == NULL) current_encoding = nl_langinfo (CODESET); diff --git a/gcc/java/jv-scan.c b/gcc/java/jv-scan.c index 90e16e7cec94..e1bc5729345a 100644 --- a/gcc/java/jv-scan.c +++ b/gcc/java/jv-scan.c @@ -33,7 +33,7 @@ Boston, MA 02111-1307, USA. */ #include #endif -#ifdef HAVE_NL_LANGINFO +#ifdef HAVE_LANGINFO_CODESET #include #endif @@ -205,7 +205,7 @@ main (int argc, char **argv) /* There's no point in trying to find the current encoding unless we are going to do something intelligent with it -- hence the test for iconv. */ -#if defined (HAVE_LOCALE_H) && defined (HAVE_ICONV) && defined (HAVE_NL_LANGINFO) +#if defined (HAVE_LOCALE_H) && defined (HAVE_ICONV) && defined (HAVE_LANGINFO_CODESET) setlocale (LC_CTYPE, ""); if (encoding == NULL) encoding = nl_langinfo (CODESET);