This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: stdbool doesn't work
- To: Mike Stump <mrs at windriver dot com>
- Subject: Re: stdbool doesn't work
- From: Gabriel Dos Reis <Gabriel dot Dos-Reis at cmla dot ens-cachan dot fr>
- Date: 08 Mar 2001 07:36:11 +0100
- Cc: gcc at gcc dot gnu dot org, zackw at stanford dot edu
- Organization: CMLA, ENS Cachan -- CNRS UMR 8536 (France)
- References: <200103080130.RAA13563@kankakee.wrs.com>
Mike Stump <mrs@windriver.com> writes:
| 2001-03-01 Zack Weinberg <zackw@stanford.edu>
|
| * configure.in: Detect stdbool.h.
| * configure, config.in: Regenerate.
| * system.h: Include stddef.h here if available.
| Set HAVE__BOOL based on GCC_VERSION and __STDC_VERSION__.
| Then set up a sensible boolean type at the very end.
|
| seems to cause me build problems, I have an older gcc on my system
| from 20010108, that has stdbool.h, but no _Bool type (or has bugs in
| it). I can use the below to work around the problem.
|
| Doing diffs in system.h.~1~:
| *** system.h.~1~ Mon Mar 5 14:26:43 2001
| --- system.h Wed Mar 7 12:13:07 2001
| *************** extern void *alloca (__SIZE_TYPE__);
| *** 575,580 ****
| --- 565,571 ----
|
| #ifdef HAVE_STDBOOL_H
| # include <stdbool.h>
| + #define _Bool char
| #else
| # if !HAVE__BOOL
| typedef char _Bool;
| --------------
|
| :-(
|
| The autoconf tests need to be better, and detect when HAVE_STDBOOL_H
| is defined, but _Bool isn't.
Thanks Mike, I reported a similar problem two days ago. It was
decided that some snapshots were not supported in order to booststrap
GCC :-(
-- Gaby
CodeSourcery, LLC http://www.codesourcery.com