From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22011 invoked by alias); 28 Nov 2010 03:03:54 -0000 Received: (qmail 22003 invoked by uid 22791); 28 Nov 2010 03:03:53 -0000 X-SWARE-Spam-Status: No, hits=-1.7 required=5.0 tests=AWL,BAYES_00,TW_CX,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from bromo.med.uc.edu (HELO bromo.med.uc.edu) (129.137.3.146) by sourceware.org (qpsmtpd/0.43rc1) with SMTP; Sun, 28 Nov 2010 03:03:47 +0000 Received: from bromo.med.uc.edu (localhost.localdomain [127.0.0.1]) by bromo.med.uc.edu (Postfix) with ESMTP id 61A2CB2DE9; Sat, 27 Nov 2010 22:03:45 -0500 (EST) Received: (from howarth@localhost) by bromo.med.uc.edu (8.14.3/8.14.3/Submit) id oAS33iru023137; Sat, 27 Nov 2010 22:03:44 -0500 Date: Sun, 28 Nov 2010 13:28:00 -0000 From: Jack Howarth To: gcc-patches@gcc.gnu.org Cc: joseph@codesourcery.com, Ralf.Wildenhues@gmx.de Subject: [PATCH,, PR46650][Revised] Fix --enable-build-with-cxx bootstrap failure Message-ID: <20101128030344.GA23135@bromo.med.uc.edu> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.18 (2008-05-17) Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org X-SW-Source: 2010-11/txt/msg02714.txt.bz2 Currently the --enable-build-with-cxx bootstrap is broken due to r167010 which poisoned the strerror macro. The attached patch includes the cstring c++ header when __cplusplus is defined. The previous includes for string.h and strings.h are left in place for symbols like strcasecmp. Bootstrap and regression tested on x86_64-apple-darwin10. http://gcc.gnu.org/ml/gcc-testresults/2010-11/msg02329.html Okay for gcc trunk? Jack 2010-11-27 Jack Howarth Joseph Myers PR bootstrap/46650 * gcc/system.h: Include cstring for cxx bootstrap. Index: gcc/system.h =================================================================== --- gcc/system.h (revision 167217) +++ gcc/system.h (working copy) @@ -194,6 +194,10 @@ rely on (and therefore test) GCC's string builtins. */ #define __NO_STRING_INLINES +#ifdef __cplusplus +# include +#endif + #ifdef STRING_WITH_STRINGS # include # include