This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Fix PR38862 (bootstrap failure graphite vs. static linking)


"Dave Korn" <dave.korn.cygwin@googlemail.com> writes:

>   Got any thoughts on how to go about linking cc1 (and friends) against
> -lstdc++ during bootstrap? ;-)

One issue is the handling of stage 1.  Until we convert gcc to be
written in C++, we are not going to want to require a C++ compiler in
order to build gcc.  Therefore, until that is done, we would need a
four stage bootstrap.  The first stage would build without requiring
the C++ libraries.  We would build both the C and C++ compilers, and
libstdc++, in that stage.  Then stage2 would be built with the full
configuration, and would link against the libstdc++ built in stage 1.
We would then need two more stages for a proper bootstrap comparison
test, because since stage1 and stage2 are configured differently,
stage2 and stage3 would be different.

Presumably enabling a four stage bootstrap would just mean hacking up
Makefile.def and Makefile.tpl some more.  Then we could just link
explicitly against the libstdc++ in the previous stage.  In general I
think it will work to simply add -lstdc++ and perhaps -lm; I don't
think it would be necessary to actually do the link with the g++
driver.

Ian


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]