t transitive includes than
libstdc++, and some of those transitive includes pull in various ctype
declarations (typically via ).
There was already a special case for including before
safe-ctype.h, so move the rest of the C++ standard header includes to
the same location, to fix the problem
Ping. It would be nice to get this QoL fix in.
-Dimitry
> On 28 Sep 2023, at 18:37, Dimitry Andric wrote:
>
> Ref: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111632
>
> When building gcc's C++ sources against recent libc++, the poisoning of
> the ctype macros due to
org/bugzilla/attachment.cgi?id=57639 :
commit 49222b98ac8e30a4a042ada0ece3d7df93f049d2
Author: Dimitry Andric
Date: 2024-03-06T23:46:27+01:00
Fix libcc1plugin and libc1plugin to use INCLUDE_VECTOR before including
system.h, instead of directly including , to avoid running into
poison
Ref: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111632
Use INCLUDE_VECTOR before including system.h, instead of directly
including , to avoid running into poisoned identifiers.
Signed-off-by: Dimitry Andric
---
libcc1/libcc1plugin.cc | 3 +--
libcc1/libcp1plugin.cc | 3 +--
2 files changed
On 13 Mar 2024, at 12:30, Iain Sandoe wrote:
>
>> On 7 Mar 2024, at 16:48, Dimitry Andric wrote:
>>
>> Ref: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111632
>>
>> Use INCLUDE_VECTOR before including system.h, instead of directly
>> including , to
As discussed with the FreeBSD gcc ports maintainer [1], building trunk
gcc with libc++ requires standard C++ headers to be included *before*
gcc/system.h, otherwise the redefinition of abort() to fancy_abort()
will cause trouble.
In r235362, most gcc C++ sources were updated to define INCLUDE_xxx
). Proposed ChangeLog entry:
2017-01-31 Dimitry Andric
* system.h: For C++, always include .
* graphite-isl-ast-to-gimple.c: Include standard C++ headers before
system.h.
* auto-profile.c: Likewise. Also remove string.h, since it is already
included in system.h
On 01 Feb 2017, at 01:23, David Edelsohn wrote:
...
>> In trunk r235362, most gcc C++ sources were updated to define
>> INCLUDE_xxx macros before including gcc/system.h, which fixes the
>> incompatibility with libc++. However, this revision is most likely too
>> disruptive to backport to the gcc-
Ref: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118685
This ensures that gcc uses its own crt objects for static linking.
Otherwise, it could mix the base system's crtbeginT.o with libgcc's
crtend.o, leading to possible segfaults.
Signed-off-by: Dimitry Andric
---
libgcc/confi