Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/share/mk Rename _MNUMBERS to _MSECTIONS. The manual section...
details: https://anonhg.NetBSD.org/src/rev/06728ce7c1ad
branches: trunk
changeset: 790898:06728ce7c1ad
user: apb <apb%NetBSD.org@localhost>
date: Fri Oct 25 22:16:29 2013 +0000
description:
Rename _MNUMBERS to _MSECTIONS. The manual section identifiers
are not just numbers any more.
Also introduce a new variable, _MSECTIONREGEX, as a regular expression
to match any of the elements of ${_MSECTIONS}. Use this instead of
\.[1-9][a-z]*.
diffstat:
share/mk/bsd.man.mk | 25 +++++++++++++------------
1 files changed, 13 insertions(+), 12 deletions(-)
diffs (73 lines):
diff -r c4cffc1bd655 -r 06728ce7c1ad share/mk/bsd.man.mk
--- a/share/mk/bsd.man.mk Fri Oct 25 22:15:02 2013 +0000
+++ b/share/mk/bsd.man.mk Fri Oct 25 22:16:29 2013 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.man.mk,v 1.113 2013/10/25 10:45:01 apb Exp $
+# $NetBSD: bsd.man.mk,v 1.114 2013/10/25 22:16:29 apb Exp $
# @(#)bsd.man.mk 8.1 (Berkeley) 6/8/93
.include <bsd.init.mk>
@@ -31,9 +31,10 @@
MAN?=
MLINKS?=
-_MNUMBERS= 1 2 3 4 5 6 7 8 9
-_MNUMBERS+= 3lua 9lua
-.SUFFIXES: ${_MNUMBERS:@N@.$N@}
+_MSECTIONS= 1 2 3 4 5 6 7 8 9
+_MSECTIONS+= 3lua 9lua
+_MSECTIONREGEX= ${_MSECTIONS:ts|} # e.g. 1|2|3|...
+.SUFFIXES: ${_MSECTIONS:@N@.$N@}
.if ${MKMANZ} == "no"
MANCOMPRESS?=
@@ -74,9 +75,9 @@
realall: ${MANPAGES}
.if !empty(MANSUFFIX)
.NOPATH: ${MANPAGES}
-.SUFFIXES: ${_MNUMBERS:@N@.$N${MANSUFFIX}@}
+.SUFFIXES: ${_MSECTIONS:@N@.$N${MANSUFFIX}@}
-${_MNUMBERS:@N@.$N.$N${MANSUFFIX}@}: # build rule
+${_MSECTIONS:@N@.$N.$N${MANSUFFIX}@}: # build rule
${_MKTARGET_FORMAT}
cat ${.IMPSRC} ${MANCOMPRESS} > ${.TARGET}.tmp && mv ${.TARGET}.tmp ${.TARGET}
.endif # !empty(MANSUFFIX)
@@ -124,14 +125,14 @@
.if (${MKCATPAGES} != "no") && (${MKMAN} != "no")
catinstall: catpages catlinks
catpages:: # ensure target exists
-CATPAGES= ${MAN:C/\.([1-9][a-z]*)$/.cat\1${MANSUFFIX}/}
+CATPAGES= ${MAN:C/\.(${_MSECTIONREGEX})\$/.cat\1${MANSUFFIX}/}
realall: ${CATPAGES}
.NOPATH: ${CATPAGES}
-.SUFFIXES: ${_MNUMBERS:@N@.cat$N${MANSUFFIX}@}
+.SUFFIXES: ${_MSECTIONS:@N@.cat$N${MANSUFFIX}@}
.MADE: ${CATDEPS}
-${_MNUMBERS:@N@.$N.cat$N${MANSUFFIX}@}: ${CATDEPS} # build rule
+${_MSECTIONS:@N@.$N.cat$N${MANSUFFIX}@}: ${CATDEPS} # build rule
${_MKTARGET_FORMAT}
.if ${MKMANDOC} == yes && !defined(NOMANDOC)
if test ""${NOMANDOC.${.IMPSRC:T}:tl:Q} != "yes"; then \
@@ -192,16 +193,16 @@
.if (${MKHTML} != "no") && (${MKMAN} != "no") # {
htmlinstall: htmlpages htmllinks
htmlpages:: # ensure target exists
-HTMLPAGES= ${MAN:C/\.([1-9][a-z]*)$/.html\1/}
+HTMLPAGES= ${MAN:C/\.(${_MSECTIONREGEX})\$/.html\1/}
HTMLLINKS= ${MANSUBDIR:?../:}../html%S/%N.html
HTMLSTYLE= ${MANSUBDIR:?../:}../style.css
realall: ${HTMLPAGES}
.NOPATH: ${HTMLPAGES}
-.SUFFIXES: ${_MNUMBERS:@N@.html$N@}
+.SUFFIXES: ${_MSECTIONS:@N@.html$N@}
-${_MNUMBERS:@N@.$N.html$N@}: # build rule
+${_MSECTIONS:@N@.$N.html$N@}: # build rule
${_MKTARGET_FORMAT}
.if ${MKMANDOC} == yes && !defined(NOMANDOC)
if test ""${NOMANDOC.${.IMPSRC:T}:tl:Q} != "yes"; then \
Home |
Main Index |
Thread Index |
Old Index