tech-pkg archive

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

Re: Fixing configure failures from newer gcc



* On 2025-10-20 at 06:28 BST, Benny Siegert wrote:

On Sun, 19 Oct 2025, Andrew Cagney wrote:

To me, a project shipping with -Werror on by default signals that they
take their code quality seriously.
It's then up to downstream to decide what to do with this - strip
-Werror and ship - or notice that the warning is for a real problem
and file a bug.

I disagree. While a project may use -Werror during development, handing such a build option to a user is a bad idea. As a user, I want to build your software, not fix warnings. The user may be on a different OS, architecture, etc., triggering different warnings, which are now errors.

Shipping a build that works is the right thing to do. This means not setting -Werror in releases.

There are ways of doing this that can accommodate everyone. For a while I shipped pkgin with a high WARNS enabled, but like you say the problem is that the errors are not consistent (IMO a bug) and I'd get reports of failures on some esoteric platform that I was unable to test on, whereas all my builds with extensive -Werror prior to release were clean.

Yes, eventually this meant that the code improved, but users were left with the impression that the software was shoddy ("don't they even test builds before release?!").

I've settled on hiding them behind --enable-maintainer-mode which is disabled in the pkgsrc build, so if you build pkgin from source manually then you'll get the warnings enabled, but in pkgsrc (where you just want a working build) they are turned off.

--
Jonathan Perkin                    pkgsrc.smartos.org
Open Source Complete Cloud   www.tritondatacenter.com


Home | Main Index | Thread Index | Old Index