From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 6AA7C138334 for ; Thu, 13 Sep 2018 16:03:57 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id E2EC4E0D63; Thu, 13 Sep 2018 16:03:53 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 80E3CE0D05 for ; Thu, 13 Sep 2018 16:03:53 +0000 (UTC) Received: from gentoo.org (unknown [IPv6:2001:980:3ff0:64:5054:ff:fe0b:7015]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: grobian) by smtp.gentoo.org (Postfix) with ESMTPSA id 074A9335D09 for ; Thu, 13 Sep 2018 16:03:51 +0000 (UTC) Date: Thu, 13 Sep 2018 18:03:47 +0200 From: Fabian Groffen To: gentoo-dev@lists.gentoo.org Subject: Re: [gentoo-dev] Changing policy about -Werror Message-ID: <20180913160347.GC26329@gentoo.org> Mail-Followup-To: gentoo-dev@lists.gentoo.org References: <20180909143221.21d784d02f51623e8c57c545@gentoo.org> <1536510660.863.9.camel@gentoo.org> <20180910074539.GA6512@baraddur.perfinion.com> <0d8b7f02-9c38-969c-413b-69d4dee6ca89@gentoo.org> <20180912085649.GA16516@baraddur.perfinion.com> <6c18c6bd-4cf3-dff6-2f20-c021063e01fa@gentoo.org> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-dev@lists.gentoo.org Reply-to: gentoo-dev@lists.gentoo.org MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="8X7/QrJGcKSMr1RN" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (SunOS 5.11, VIM - Vi IMproved 8.1) Organization: Gentoo Foundation, Inc. X-Archives-Salt: 3e24b4bd-5f22-481c-a37f-3d533e5f046a X-Archives-Hash: 1135b159783ea5941e055c6c2ba6ea28 --8X7/QrJGcKSMr1RN Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 13-09-2018 07:36:09 -0400, Richard Yao wrote: >=20 >=20 > > On Sep 12, 2018, at 6:55 PM, Thomas Deutschmann wro= te: > >=20 > >> On 2018-09-12 16:50, Rich Freeman wrote: > >> There is also the case where we want these warnings to block > >> installation, because the risk of there being a problem is too great. > >=20 > > I really disagree with that. So many devs have already said multiple > > times in this thread that "-Werror" is only turning existing warnings > > into fatal errors but "-Werror" itself doesn't add any new checks and > > more often requires "-O3" to be useful. > The way that compilers work is that the warnings are generated in the fro= nt end while the optimization level affects the backend. That means that -O= 3 has no effect on the code that does error generation. This remark about -= O3 being needed to make -Werror useful is just plain wrong.=20 Huh? -O3 enables more checks, which can generate more warnings. -O3 isn't "needed", but if upstream is so interested in clean and correct code, they should've fixed all warnings in the first place and thus enabled all of them. In fact, I expect every sane upstream to use "-O3 -Wall -Werror" in one of their automated builds. Not that this catches anything useful on x86{,_64} when there is for instance use of signed and unsigned char types, so it isn't conclusive. The whole point in here is that -Werror doesn't add much if you care. The whole point why it is not desired in Gentoo is that users don't necessarily are developers, or even interested in fixing warnings -- regardless whether they point to real problems or not. If there are real problems in a package (exposed by a compiler or not) then this should ideally stand out during ~arch testing, or even before when the Gentoo maintainer examines the build (might even use -Werror for his own purposes). If such code ends up in stable arch we just made a stabilisation mistake, or got royally messed up by upstream, depending how you look at it. Fabian --=20 Fabian Groffen Gentoo on a different level --8X7/QrJGcKSMr1RN Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEELUvHd/Gtp7LaU1vuzpXahU5EQpMFAluaimMACgkQzpXahU5E QpNorgf/aJY2cX6ur4Ohmg/YhVtm1fvbEmo0Sbcpqf3N9Dx+4FqOWsAwuA4+dLKe EeW0IvjyZ/9az89YSCXAq2IVrvIw+8DNc7EHf/7+ttt8nWoUy83Ri4er+/P4XK7s m15UAxn0v3CO2aH8OyoKN5M/hqZEOcH8+jXR40VIG7EIgDA1bawugCcawlMk5O9A JnZs44CzfENweaBKWysZpw4KlyY6rzKKhAB427VHkJYpOKJUwvtjkulndSJrOMAj fdgblggVLi+AM6ZwCjsoQoI63uKnGC+gfRVNhjZKKL3V3gUU1bQhNObhKFHkvUl8 /RmANqX+AXD2FZmFPQu7/KFGin//LQ== =lpY4 -----END PGP SIGNATURE----- --8X7/QrJGcKSMr1RN--