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 RFA: Build system: Use AC_SYS_LARGEFILE


Paolo's earlier patch #undef'ing _LARGE_FILES works and allows me to
bootstrap; still running testsuite.

I agree about the potential problems, although gengtype is fairly independent.

I am worried about defining _LARGE_FILES in CFLAGS causing other
problems because that will cause many other files that do not use
auto-hosts.h to be compiled with _LARGE_FILES support with unknown
affects.

Inserting bconfig.h first seems the most localized approach.

Thanks, David

On Tue, Nov 9, 2010 at 11:55 AM, Paolo Bonzini <bonzini@gnu.org> wrote:
> On 11/09/2010 05:46 PM, Ian Lance Taylor wrote:
>>
>> David Edelsohn<dje.gcc@gmail.com> ?writes:
>>
>>> With Paolo's patch, my bootstrap has progressed into stage 2.
>>> Hopefully the Flex-generated file is the only case where header files
>>> are included in the wrong order. ?Paolo's patch definitely is a step
>>> in the right direction.
>>
>> Paolo's patch makes me a little bit uncomfortable because it means that
>> gengtype-lex.l is compiled with a different ABI than the rest of the
>> compiler. ?Of course it's a very simple file and it doesn't use any
>> aspect of the ABI. ?But it does call fopen and fclose. ?If a call to
>> fseeko ever sneaks in there somehow, it will break on AIX in a rather
>> mysterious manner.
>
> I agree. ?I had considered this too but then went for the inferior patch for
> a reason:
>
> Index: Makefile.in
> ===================================================================
> --- Makefile.in (revision 166028)
> +++ Makefile.in (working copy)
> @@ -3949,7 +3949,11 @@ $(genprog:%=build/gen%$(build_exeext)):
>
> ?# Generated source files for gengtype.
> ?gengtype-lex.c : gengtype-lex.l
> - ? ? ? -$(FLEX) $(FLEXFLAGS) -o$@ $<
> + ? ? ? -$(FLEX) $(FLEXFLAGS) -o$@ $< && { \
> + ? ? ? ? echo '#include "bconfig.h"' > $@.tmp; \
> + ? ? ? ? cat $@ >> $@.tmp; \
> + ? ? ? ? mv $@.tmp $@; \
> + ? ? ? }
>
> ?#
>
> ?# Remake internationalization support.
>
> The advantage of this, if anything, is that something like that might be
> wrapped in automake's ylwrap script.
>
> However, Ian---depending on the order in which David tests the various
> approaches, your patch is okay if it works.
>
> Paolo
>


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