PATCH RFA: Build stages 2 and 3 with C++
Ian Lance Taylor
iant@google.com
Sat Jul 16 07:48:00 GMT 2011
Andrew Pinski <pinskia@gmail.com> writes:
> On Fri, Jul 15, 2011 at 11:52 PM, Ian Lance Taylor <iant@google.com> wrote:
>> I would like to propose this patch as a step toward building gcc using a
>> C++ compiler. This patch builds stage1 with the C compiler as usual,
>> and defaults to building stages 2 and 3 with a C++ compiler built during
>> stage 1. This means that the gcc installed and used by most people will
>> be built by a C++ compiler. This will ensure that gcc is fully
>> buildable with C++, while retaining the ability to bootstrap with only a
>> C compiler, not a C++ compiler. This will permit us to experiment with
>> optionally using C++ for some code, using a #ifdef to select the C
>> implementation or the C++ implementation.
>>
>> I would suggest that we consider releasing 4.7 this way, as a small
>> trial for building gcc with C++.
>
> Do you build libstdc++ at stage1 also? That is what happens if you
> don't have a C++ compiler to begin with.
Yes. With this patch, we build cc1plus at stage 1, and use it to build
libstdc++ at stage 1, and use both to build stage 2.
Ian
More information about the Gcc
mailing list