From nobody Sun Jun 28 00:44:13 2026 X-Original-To: dev-commits-src-all@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 4gnrJg4MvXz6jFWn for ; Sun, 28 Jun 2026 00:44: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 "YR1" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4gnrJg0Gm6z3lnr for ; Sun, 28 Jun 2026 00:44:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1782607459; 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=lsI/xkKNU81AVctyhRBoWOVPMONrwCfOg+Wydsd+MEc=; b=HokRDDZaYGujBI0aMgqgRpsMgi4tPqR44ql6MHMciJKI91hILZ5mfbAXa/BDfP3BDKpvkd NWGuCY932ICqgZhMiPR9DfrL4abSQEaLCWz7/S+IXbzme2SLGxyufPfZFjf/eQaZn8Oz/U TO3OsVTRt+SY7q77+JM1vwhibhbN0eKHNb/hWRQgzHFeWaLAPq99skQnP+ojvxK/fea1/l hWRIHZj0E1opogBZ7PfjJ7rH9IBIIu7yrGtTfYd1zK2U7V1JBZr3A8WTXQOhRUhn9ny6A6 ErK1TysoHzO+bqIhYp7SQg2F4OF5APTPHrclXHY+GCSpVpXbHzJ3tWV6093fYA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1782607459; a=rsa-sha256; cv=none; b=mt0QUErz/cN+jSAAC0jaATFi1Dx/O35lMkuQL0PrziQdBDrNbCsn0zsqfC5dz0xOtVV0q/ nWAQNtMKwCob4IpCOxA9TIraNBAaD8hcYWpWpLRPJHYrVA0Mh+p4xc+VwjqDRBK5v9sJhW 0M6v9MRaehg01qnQ7Oz4pQ9Y5jxO2MQs8EcN0KXPT8IOVGuI7g6cB377jwDqxJctNkggKG v5G9IqOwQEZbVsC1Giz9UnYDFsTvJeZxrkoQPzzQUX3mIu2GkbPYGQwKPPvNuXSWfPJYOV iRO9piMKDg8OQ9FNQMVnyp7BJd1bVnsj402so7zaqBC7be20o/zylbVpx+uAYg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1782607459; 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=lsI/xkKNU81AVctyhRBoWOVPMONrwCfOg+Wydsd+MEc=; b=Wg74FPTDCZj0L+OtygX2zc86cQz32RP0ePwYAhrnm/NyQy68XdFeyxggN6d/iooKybia/m /YbIvUc7OxXVuwZA68hOauR08DH8TR9BNC9RJOeBmjczRx0pduzUFJ1Gqf9Df5TXrRN77a latw+y7FXZcxqDYHiyzpZNb2OXMo3TYqeibRrt9EwUKcqpoM5cIgaWOO66T87oUooZRofA 3xegMY8WZfbIer6KspVFyr3fnExeFGamcZz8vDxA1DW5mRfvmJoG1u/NAXSiRyPi/bzdLz RadBqA6RpwhSqwSQYEYlx5Ihch0J/4pgBEoZcwcNV1ZWv30t30FEFR+6cceoZQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4gnrJf3y2vznWw for ; Sun, 28 Jun 2026 00:44:18 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3f1c1 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Sun, 28 Jun 2026 00:44:13 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Alexander Ziaee Subject: git: 4016f9d5fedd - stable/15 - mdoc.7: Revert upstream changes to Lb/LIBRARY List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: ziaee X-Git-Repository: src X-Git-Refname: refs/heads/stable/15 X-Git-Reftype: branch X-Git-Commit: 4016f9d5feddfb13bcb8cbf6a70378e4d0cb6049 Auto-Submitted: auto-generated Date: Sun, 28 Jun 2026 00:44:13 +0000 Message-Id: <6a406e5d.3f1c1.a1ca438@gitrepo.freebsd.org> The branch stable/15 has been updated by ziaee: URL: https://cgit.FreeBSD.org/src/commit/?id=4016f9d5feddfb13bcb8cbf6a70378e4d0cb6049 commit 4016f9d5feddfb13bcb8cbf6a70378e4d0cb6049 Author: Alexander Ziaee AuthorDate: 2026-05-22 18:09:23 +0000 Commit: Alexander Ziaee CommitDate: 2026-06-28 00:36:10 +0000 mdoc.7: Revert upstream changes to Lb/LIBRARY Since this manual describes the mdoc syntax throughout the ecosystem, I had to blend what we had before with what upstream is doing now. Thanks: adrian MFC after: 3 days (we shipped this doc in 15.0/14.4) Reviewed by: ivy, mhorne, des, adrian Discussed with: arch@ Differential Revision: https://reviews.freebsd.org/D56153 (cherry picked from commit 4e2bf6e90a65bee317e4dd379e098ba2eb5d8c0d) --- contrib/mandoc/mdoc.7 | 37 +++++++++++++++++++++++++++++++++---- 1 file changed, 33 insertions(+), 4 deletions(-) diff --git a/contrib/mandoc/mdoc.7 b/contrib/mandoc/mdoc.7 index 90f5600c59a7..7346cf25da65 100644 --- a/contrib/mandoc/mdoc.7 +++ b/contrib/mandoc/mdoc.7 @@ -196,8 +196,14 @@ and .Ic \&Nd . .It Em LIBRARY The name of the library containing the documented functions. -Using this section is no longer recommended. -If any +The syntax for this is as follows: +.Bd -literal -offset indent +\&.Lb libm +.Ed +.Pp +Using this section is no longer recommended outside +.Fx . +If writing for other operating systems, and any .Ic \&Lb macro is needed, put it at the beginning of the .Em SYNOPSIS @@ -223,7 +229,7 @@ Commands should be ordered alphabetically. .Pp For the second, function calls (sections 2, 3, 9): .Bd -literal -offset indent -\&.Lb libname \e" unless the functions are in libc +\&.Lb libname \e" unless on FreeBSD or the functions are in libc \&.In header.h \&.Vt extern const char *global; \&.Ft char * @@ -1880,7 +1886,30 @@ See also .Tg Lb .It Ic \&Lb Cm lib Ns Ar name Op Cm lib Ns Ar name ... Specify one or more libraries to link against. -Putting this macro at the beginning of the +.Pp +If used in the +.Em LIBRARY +section, the +.Ar name +parameter may be a system library, such as +.Cm z +or +.Cm pam , +in which case a small library description is printed next to the linker +invocation; or a custom library, in which case the library name is +printed in quotes. +This is most commonly used in the +.Em LIBRARY +or +.Em SYNOPSIS +sections, as described in +.Sx MANUAL STRUCTURE. +.Pp +Examples: +.Dl \&.Lb libz +.Dl \&.Lb libmandoc +.Pp +In other operating systems, putting this macro at the beginning of the .Em SYNOPSIS section is recommended, in which case it prints this comment: .D1 /* Fl l Ns Ar name Oo Fl l Ns Ar name ... Oc */