public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Sergiy Vyshnevetskiy <serg@vostok.net>
To: gcc-patches@gcc.gnu.org
Cc: gerald@pfeifer.com, tromey@gcc.gnu.org
Subject: [PATCH][BUGFIX][PR 31932] cpp: Remove useless HAVE_ICONV_H [1/2]
Date: Fri, 18 May 2007 19:02:00 -0000	[thread overview]
Message-ID: <Pine.LNX.4.64.0705182156040.2122@uanet.vostok.net> (raw)
In-Reply-To: <Pine.LNX.4.64.0705181549010.2122@uanet.vostok.net>

[-- Attachment #1: Type: TEXT/PLAIN, Size: 972 bytes --]

Parts of cpp are compiled without libiconv when it's present in the system 
in a non-default location and --with-libiconv-prefix specified correctly.

The reason for this is usage of HAVE_ICONV_H macro in libcpp/internal.h

1. The check for iconv.h in libcpp/configure does not use the value of
--with-libiconv-prefix option.

2. HAVE_ICONV_H is useless because check for libiconv in libcpp/configure
    uses iconv.h anyway.

3. HAVE_ICONV is changed in libcpp/internal.h like this:

#ifndef HAVE_ICONV_H
#undef HAVE_ICONV
#endif

which is inherently incorrect in and of itself: any information produced by 
configure must not be changed in the source code. If configure tests don't 
work right - fix them, but all source code must be compiled with the same 
global settings.

Solution: get rid of HAVE_ICONV_H in libcpp/internal.h.



2007-05-18  Sergiy Vyshnevetskiy  <serg@vostok.net>

 	 PR propocessor/31932
 	 * internal.h: Remove unnecessary usage of HAVE_ICONV_H

[-- Attachment #2: Type: TEXT/PLAIN, Size: 274 bytes --]

--- libcpp/internal.h.orig	Fri Oct 21 20:54:20 2005
+++ libcpp/internal.h	Sat May 12 21:47:11 2007
@@ -26,10 +26,6 @@
 #include "symtab.h"
 #include "cpp-id-data.h"
 
-#ifndef HAVE_ICONV_H
-#undef HAVE_ICONV
-#endif
-
 #if HAVE_ICONV
 #include <iconv.h>
 #else

      parent reply	other threads:[~2007-05-18 19:02 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-05-18 13:23 [PATCH][BUGFIX][gcj 4.1,4.2][PR 31932] gcj: " Sergiy Vyshnevetskiy
2007-05-18 13:29 ` [PATCH][BUGFIX][gcj 4.1,4.2][PR 31932] gcj: Remove useless HAVE_ICONV_H [2/2] Sergiy Vyshnevetskiy
2007-05-18 19:04   ` [PATCH][BUGFIX][PR 31932] cpp: " Sergiy Vyshnevetskiy
2007-05-18 19:02 ` Sergiy Vyshnevetskiy [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=Pine.LNX.4.64.0705182156040.2122@uanet.vostok.net \
    --to=serg@vostok.net \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=gerald@pfeifer.com \
    --cc=tromey@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).