From nobody Thu Oct 30 04:47:19 2025 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4cxs6H2hc2z6Dlnt; Thu, 30 Oct 2025 04:47:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4cxs6H20zwz3Pwt; Thu, 30 Oct 2025 04:47:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1761799639; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=PTTR9uiK43RSOy5zt9CrX7ROH3GoLih8DQIMZCtjwLw=; b=S8VpK6VD+1m6i6Uj/BIejs7lpPGCH+vbXKbuwDMesFrjxayljhdlk65WmjMkrOK64Fg/P/ 2H9Conu4d593A1BwrXPof6zw3YN4eTvxBKkCMQE+asX0YPrU36FR1b3dhOe4y7iKonuDXn PquP0oYqAe1UI/tgl6/O5A4TaHJXzbKVO9fJZTRoil1PtQSVTEjF73mKJs6brurhdMGtOi sH+hcBHOH5iB0izFTVtBaJ3TU/GNV2SWKBpCaqKr21YGAiMlTA+DUimaGu5AKUAGa7b170 KkCk13xQK54cK5TfpsAjRy+haoH1IIuuP1JZJ0sUtoxWutUx8w0TNl/AXX1J6Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1761799639; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=PTTR9uiK43RSOy5zt9CrX7ROH3GoLih8DQIMZCtjwLw=; b=q63tEr0cfNvjHuwe1NvN22rGBVkcPP8MBak064X1SlPbySMmDlgdw7eIO+Qm/IgEO5z/4L naaYJ29GYxKDjznrPL+7kqfmLExlQ/OQ48jQlQeymIsN/YB+SA/eeJ+HZwgU5rax/+LVJG YUQMxGN83izXaAUqfyc430rk6kr6fWbYC6XEoAaOAN1m/94xCVMz/Z3lUVBd9hb0G/u2Sb ZTtNRRjSdGj26rH8krFE8pfiRPsZzpb+ve1wOr6jJHVQGyinnyfwVvJ6mz8AfGd2LSMTeT r22YCRWaVkfu5kdFErDYcKbwhcRrVXS7CI7xLM5CkaXwfRwaKEvXP+nJeRGEQA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1761799639; a=rsa-sha256; cv=none; b=fC0PO9TzdXrScg/p6UQ8ATzXvItVHgxJaTE8/G/gcJ5FpLd4E4Gc0HKFcNiMbPSyxKtbRx J7M5Q3OYYJx+yBnMGSAbVkf1guffncIzQ1fm19JX7HAgLu0tZHNi739cjklajQjoIfS/IW NhL+Mn+falSppZsdvlud0oX0E5GnD6wmPQ5MXLVrO35fIJVFByeQp1LWz+aNPPfrj7Leb7 uM6suUDggT1tc1cFxxuxezhTlAGraArk7pSMWiLU1gxtUfLicytUSFkyMhEM6tyu+PqDgy Pc1iatet0bhuYAiXPqvHjY8j/fRZ/NK/FhWT8v8ILAAe5ob1s+eUx7jHhZJe8Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4cxs6H1ZfQz16gt; Thu, 30 Oct 2025 04:47:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 59U4lJBK023998; Thu, 30 Oct 2025 04:47:19 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 59U4lJr9023995; Thu, 30 Oct 2025 04:47:19 GMT (envelope-from git) Date: Thu, 30 Oct 2025 04:47:19 GMT Message-Id: <202510300447.59U4lJr9023995@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: "David E. O'Brien" Subject: git: 237cc7b408dd - main - style.Makefile: document the style for lists List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: obrien X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 237cc7b408dd8d0c6eb4af6ab796b8d4b750c9ba Auto-Submitted: auto-generated The branch main has been updated by obrien: URL: https://cgit.FreeBSD.org/src/commit/?id=237cc7b408dd8d0c6eb4af6ab796b8d4b750c9ba commit 237cc7b408dd8d0c6eb4af6ab796b8d4b750c9ba Author: David E. O'Brien AuthorDate: 2025-10-29 07:59:18 +0000 Commit: David E. O'Brien CommitDate: 2025-10-30 03:41:59 +0000 style.Makefile: document the style for lists Reviewed by: sjg Differential Revision: https://reviews.freebsd.org/D53429 --- share/man/man5/style.Makefile.5 | 24 +++++++++++++++++++----- 1 file changed, 19 insertions(+), 5 deletions(-) diff --git a/share/man/man5/style.Makefile.5 b/share/man/man5/style.Makefile.5 index fe8754924575..9a2f1b069d99 100644 --- a/share/man/man5/style.Makefile.5 +++ b/share/man/man5/style.Makefile.5 @@ -1,7 +1,7 @@ .\" .\" SPDX-License-Identifier: BSD-3-Clause .\" -.\" Copyright (c) 2002-2003, 2023 David O'Brien +.\" Copyright (c) 2002-2003, 2023, 2025 David O'Brien .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without @@ -28,7 +28,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd July 17, 2023 +.Dd October 29, 2025 .Dt STYLE.MAKEFILE 5 .Os .Sh NAME @@ -179,6 +179,21 @@ settings between the and .Fl I Ns 's. .It +Lists that span more than one line should be formatted as follows: +.Bd -literal -offset indent +SRCS+=\\ +main.c\\ +trace.c\\ +zoo.c \\ +\& +.Ed +Specifically, the last item in the list should have a trailing '\\'. +This is to avoid causing a "false diff" or "false blame" when +a new item is appended at the end. +In general the list should be English language alphabetized. +A list of libraries or header inclusion paths are notable exceptions +if needed for proper building. +.It Do not use GCCisms (such as .Fl g and @@ -233,9 +248,6 @@ For variables that are only checked with .Fn defined , do not provide any fake value. .El -.Pp -The desire to express a logical grouping often means not obeying some of the -above. .Sh EXAMPLES The simplest program .Pa Makefile @@ -270,5 +282,7 @@ manual page and first appeared in .An David O'Brien Aq deo@NUXI.org .Sh BUGS There are few hard and fast style rules here. +The desire to express a logical grouping sometimes means not obeying some of the +above. The style of many things is too dependent on the context of the whole makefile, or the lines surrounding it.