grep-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Grep-devel] [platform-testers] new snapshot available: grep-2.25.10


From: Paul Eggert
Subject: Re: [Grep-devel] [platform-testers] new snapshot available: grep-2.25.101-be82
Date: Tue, 27 Sep 2016 11:41:02 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.3.0

On 09/27/2016 09:43 AM, Assaf Gordon wrote:
Would it be possible to consider some older GCC's as still valid
for automatically enabling warnings ?

I thought about that, but that would mean we'd have to port grep to these older compilers when configured with --enable-gcc-warnings. Older compilers often generate false alarms and we'd probably have to contort the code just to pacify the old bugs. Plus, we'd have to keep a copy of GCC 4.8 (or whatever) around just to test whether grep still builds with --enable-gcc-warnings. This sounds like more hassle than the warnings are worth.

The situation with clang is similar to that with older GCC, for C anyway. People can use --enable-gcc-warnings with clang now (as long as they don't pester us about the false alarms :-).

For what it's worth I just now tried to build grep with clang 3.8.0 on Fedora and ran into several problems, not just --enable-gcc-warnings. I'll see if I can fix them without contorting grep too much.

Effectively this means that developers using stable distributions will
need to build and install a new compiler, or forgo the warnings (which are very useful).


These developers don't need to forgo the warnings, as they can use './configure --enable-gcc-warnings'.


there are two 'main()' - not sure if this compiles successfully or not

Ouch, thanks for catching that. I didn't see it because I configured long ago with --enable-gcc-warnings (my usual practice) and the rebuild picked up that flag. Fixed with the 1st attached patch.

If we decide to keep this as-is, perhaps it would be helpful to rephrase the error message to 'Enabling warnings requires GCC=>6.2' ?

Sure, I did something like that in the 2nd attached patch. I'd rather not put the version number in the diagnostic as that'd be yet another place we have to maintain version numbers by hand.

Attachment: 0001-build-port-.git-builds-to-newer-GCC.patch
Description: Source code patch

Attachment: 0002-build-reword-.git-old-GCC-warning.patch
Description: Source code patch


reply via email to

[Prev in Thread] Current Thread [Next in Thread]