This is the mail archive of the
mailing list for the GCC project.
Re: PATCH RFA: Add --enable-build-with-cxx to gcc subdirectory
- From: Ian Lance Taylor <iant at google dot com>
- To: Paolo Bonzini <bonzini at gnu dot org>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Mon, 22 Jun 2009 06:08:48 -0700
- Subject: Re: PATCH RFA: Add --enable-build-with-cxx to gcc subdirectory
- References: <email@example.com> <4A3F39E2.firstname.lastname@example.org>
Paolo Bonzini <email@example.com> writes:
> Ok, can you just explain this?
>> +COMPILER_FLAGS = $(filter-out -fkeep-inline-functions,$(CXXFLAGS))
>> +LINKER_FLAGS = $(filter-out -fkeep-inline-functions,$(CXXFLAGS))
The top level configure.ac adds -fkeep-inline-functions to
stage1_cflags. The toplevel Makefile.in sets stage1_cxxflags to
stage1_cflags. This is intended to be a check to catch problems with
compilers which always emit a copy of an inline function. However,
this is completely wrong for C++, and in particular gmp.h has inline
functions when compiling with C++. Emitting a copy of them in each .o
file is wrong. A C++ compiler will always handle inline predictably,
so there is no need to do this check for C++.
Do you mean that the patch is OK with that explanation?