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 788C8138334
for ; Wed, 22 May 2019 19:37:32 +0000 (UTC)
Received: from pigeon.gentoo.org (localhost [127.0.0.1])
by pigeon.gentoo.org (Postfix) with SMTP id A5AE0E089E;
Wed, 22 May 2019 19:37:30 +0000 (UTC)
Received: from smtp.gentoo.org (smtp.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4])
(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 818EFE089E
for ; Wed, 22 May 2019 19:37:30 +0000 (UTC)
Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84])
(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
(No client certificate requested)
by smtp.gentoo.org (Postfix) with ESMTPS id CDFF2344E45
for ; Wed, 22 May 2019 19:37:28 +0000 (UTC)
Received: from localhost.localdomain (localhost [IPv6:::1])
by oystercatcher.gentoo.org (Postfix) with ESMTP id 720AA5EF
for ; Wed, 22 May 2019 19:37:26 +0000 (UTC)
From: "Göktürk Yüksek"
To: gentoo-commits@lists.gentoo.org
Content-Transfer-Encoding: 8bit
Content-type: text/plain; charset=UTF-8
Reply-To: gentoo-dev@lists.gentoo.org, "Göktürk Yüksek"
Message-ID: <1558553651.add4db87d50f4633dac12a21f5c0f98bc86cc5d6.gokturk@gentoo>
Subject: [gentoo-commits] proj/devmanual:master commit in: general-concepts/use-flags/
X-VCS-Repository: proj/devmanual
X-VCS-Files: general-concepts/use-flags/text.xml
X-VCS-Directories: general-concepts/use-flags/
X-VCS-Committer: gokturk
X-VCS-Committer-Name: Göktürk Yüksek
X-VCS-Revision: add4db87d50f4633dac12a21f5c0f98bc86cc5d6
X-VCS-Branch: master
Date: Wed, 22 May 2019 19:37:26 +0000 (UTC)
Precedence: bulk
List-Post:
List-Help:
List-Unsubscribe:
List-Subscribe:
List-Id: Gentoo Linux mail
X-BeenThere: gentoo-commits@lists.gentoo.org
X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply
X-Archives-Salt: 958d68b8-3610-4e42-99a5-171f0c81e748
X-Archives-Hash: ca994577d378bb523307b497f671d47a
commit: add4db87d50f4633dac12a21f5c0f98bc86cc5d6
Author: Michał Górny gentoo org>
AuthorDate: Sun Apr 14 09:44:18 2019 +0000
Commit: Göktürk Yüksek gentoo org>
CommitDate: Wed May 22 19:34:11 2019 +0000
URL: https://gitweb.gentoo.org/proj/devmanual.git/commit/?id=add4db87
general-concepts/use-flags: Also note about flags controlling CFLAGS
Signed-off-by: Michał Górny gentoo.org>
general-concepts/use-flags/text.xml | 36 ++++++++++++++++++++++++++++++++++++
1 file changed, 36 insertions(+)
diff --git a/general-concepts/use-flags/text.xml b/general-concepts/use-flags/text.xml
index c20e8d0..4d56d97 100644
--- a/general-concepts/use-flags/text.xml
+++ b/general-concepts/use-flags/text.xml
@@ -70,6 +70,42 @@ of flags to those programs or modules that have external dependencies
and/or long build times. The rest of them should be built unconditionally
instead, or controlled by a flag such as minimal.
+
+
+You should not introduce USE flags that merely manipulate CFLAGS,
+FEATURES or similar variables configured directly by the user. Instead,
+packages should avoid manipulating them at all, and let users set them directly.
+Common mistakes include:
+
+
+
+ -
+ Using debug USE flag to force -O0 -g and disable
+ stripping. The correct purpose of debug flag is to control additional
+ debug code paths. The use of correct flags and features to preserve
+ debugging information is user's responsibility.
+
+
+ -
+ Introducing lto flag to force -flto. This is something user
+ should set directly in flag varibles.
+
+
+ -
+ Using CPU_FLAGS_* to control -m* options. Those flags are
+ intended to control code paths explicitly requiring specific CPU extensions,
+ e.g. separate assembly. Compiler-generated assembly should respect user's
+ -march choice.
+
+
+
+
+There might be corner cases where these rules do not apply. For example, a few
+upstreams require users to use specific CFLAGS and reject bug reports
+against builds using other values. In this case, it is customary to strip flags
+by default and provide custom-cflags flag to allow users to force their
+preferred flags.
+