From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 11068 invoked by alias); 7 Feb 2002 21:33:20 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 10913 invoked from network); 7 Feb 2002 21:33:16 -0000 Received: from unknown (HELO cygnus.com) (205.180.230.5) by sources.redhat.com with SMTP; 7 Feb 2002 21:33:16 -0000 Received: from there (cse.cygnus.com [205.180.230.236]) by runyon.cygnus.com (8.8.7-cygnus/8.8.7) with SMTP id NAA28346 for ; Thu, 7 Feb 2002 13:33:11 -0800 (PST) Message-Id: <200202072133.NAA28346@cygnus.com> Content-Type: text/plain; charset="iso-8859-1" From: "Martin M. Hunt" Organization: Red Hat Inc To: gdb-patches@sources.redhat.com Subject: [RFA] fix for utils.c bool problem Date: Thu, 07 Feb 2002 13:33:00 -0000 X-Mailer: KMail [version 1.3.2] MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SW-Source: 2002-02/txt/msg00197.txt.bz2 Am I the only one seeing this? On three different build systems I am getting errors like gcc -c -g -O2 -I/usr/include/v9 -I. -I../../src/gdb -I../../src/gdb/config -DHAVE_CONFIG_H -I../../src/gdb/../include/opcode -I../../src/gdb/../readline/.. -I../bfd -I../../src/gdb/../bfd -I../../src/gdb/../include -I../intl -I../../src/gdb/../intl -DMI_OUT=1 -DGDBTK -DUI_OUT=1 -Wimplicit -Wreturn-type -Wcomment -Wtrigraphs -Wformat -Wparentheses -Wpointer-arith -Wuninitialized ../../src/gdb/utils.c In file included from /usr/progressive/lib/gcc-lib/sparc-sun-solaris2.5/2.96-gnupro-00r1/include/curses.h:5, from ../../src/gdb/utils.c:30: /usr/include/curses.h:69: conflicting types for `_Bool' /usr/progressive/lib/gcc-lib/sparc-sun-solaris2.5/2.96-gnupro-00r1/include/stdbool.h:41: previous declaration of `_Bool' Some newer versions of gcc apparently have stdbool.h improvements that fix the problem. Another fix is to simply reorder the patch, which fixes builds on all of my systems (Windows, Linux, Solaris) -- Martin Hunt GDB Engineer Red Hat, Inc. 2002-02-07 Martin M. Hunt * utils.c: Reorder includes to eliminate bool conflict. Index: utils.c =================================================================== RCS file: /cvs/src/src/gdb/utils.c,v retrieving revision 1.61 diff -u -p -r1.61 utils.c --- utils.c 2002/02/05 04:37:22 1.61 +++ utils.c 2002/02/07 21:32:35 @@ -20,18 +20,18 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -#include "defs.h" -#include "gdb_assert.h" -#include -#include "gdb_string.h" -#include "event-top.h" - #ifdef HAVE_CURSES_H #include #endif #ifdef HAVE_TERM_H #include #endif + +#include "defs.h" +#include "gdb_assert.h" +#include +#include "gdb_string.h" +#include "event-top.h" #ifdef __GO32__ #include