diff options
author | Ingo Schwarze <schwarze@openbsd.org> | 2021-06-02 18:28:19 +0000 |
---|---|---|
committer | Ingo Schwarze <schwarze@openbsd.org> | 2021-06-02 18:28:19 +0000 |
commit | 81fed4ca2ec0fa379abfe067dedb8a3a4b32ab82 (patch) | |
tree | fc90cb868eb26afd126066004b40e633765d76e7 /mandoc.1 | |
parent | e4b7709a1c43fd251397020963a1ce703c8229b4 (diff) | |
download | mandoc-81fed4ca2ec0fa379abfe067dedb8a3a4b32ab82.tar.gz |
In -W style mode, check .Xr links along the full manpath because
that is more useful for validating manuals of non-base software.
Nothing changes in -W all mode: by default for -T lint, we still
assume we want to check base system conventions, including usually
not wanting to link to non-base manual pages.
The use case, a partial idea how to handle it, and a preliminary
patch was originally presented by kn@, then refined by me.
Final patch tested and OK'ed by kn@.
Diffstat (limited to 'mandoc.1')
-rw-r--r-- | mandoc.1 | 39 |
1 files changed, 30 insertions, 9 deletions
@@ -1,6 +1,6 @@ .\" $OpenBSD: mandoc.1,v 1.166 2020/02/15 15:28:01 schwarze Exp $ .\" -.\" Copyright (c) 2012, 2014-2020 Ingo Schwarze <schwarze@openbsd.org> +.\" Copyright (c) 2012, 2014-2021 Ingo Schwarze <schwarze@openbsd.org> .\" Copyright (c) 2009, 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv> .\" .\" Permission to use, copy, modify, and distribute this software for any @@ -922,14 +922,6 @@ generated by CVS or .Ic NetBSD keyword substitution as conventionally used in these operating systems. -.It Sy "referenced manual not found" -.Pq mdoc -An -.Ic \&Xr -macro references a manual page that is not found in the base system. -The path to look for base system manuals is configurable at compile -time and defaults to -.Pa /usr/share/man : /usr/X11R6/man . .El .Ss Style suggestions .Bl -ohang @@ -1016,6 +1008,35 @@ list contains two consecutive entries describing the same .Ic \&Er number. +.It Sy "referenced manual not found" +.Pq mdoc +An +.Ic \&Xr +macro references a manual page that was not found. +When running with +.Fl W Cm base , +the search is restricted to the base system, by default to +.Pa /usr/share/man : Ns Pa /usr/X11R6/man . +This path can be configured at compile time using the +.Dv MANPATH_BASE +preprocessor macro. +When running with +.Fl W Cm style , +the search is done along the full search path as described in the +.Xr man 1 +manual page, respecting the +.Fl m +and +.Fl M +command line options, the +.Ev MANPATH +environment variable, the +.Xr man.conf 5 +file and falling back to the default of +.Pa /usr/share/man : Ns Pa /usr/X11R6/man : Ns Pa /usr/local/man , +also configurable at compile time using the +.Dv MANPATH_DEFAULT +preprocessor macro. .It Sy "trailing delimiter" .Pq mdoc The last argument of an |