svn commit: r283777 - in head: . share/mk tools/build/options usr.bin usr.bin/man usr.bin/mandoc
Baptiste Daroussin
bapt at FreeBSD.org
Sat May 30 17:41:39 UTC 2015
Author: bapt
Date: Sat May 30 17:41:37 2015
New Revision: 283777
URL: https://svnweb.freebsd.org/changeset/base/283777
Log:
Switch to mandoc's version of makewhatis(8), whatis(1), apropos(1) utilities.
This change among other things improve search capabilities over the manpages
allowing fine grain query.
A new build option WITHOUT_MANDOCDB has been added to keep the ancient version
of the database and the tools. The plan is to entirely remove this option before
11.0-RELEASE.
Differential Revision: https://reviews.freebsd.org/D2603
Added:
head/tools/build/options/WITHOUT_MANDOCDB (contents, props changed)
Modified:
head/Makefile.inc1
head/share/mk/src.opts.mk
head/usr.bin/Makefile
head/usr.bin/man/Makefile
head/usr.bin/mandoc/Makefile
Modified: head/Makefile.inc1
==============================================================================
--- head/Makefile.inc1 Sat May 30 17:29:51 2015 (r283776)
+++ head/Makefile.inc1 Sat May 30 17:41:37 2015 (r283777)
@@ -1363,6 +1363,16 @@ _kerberos5_bootstrap_tools= \
.ORDER: ${_kerberos5_bootstrap_tools:C/^/${_bt}-/g}
.endif
+.if ${MK_MANDOCDB} != "no"
+_makewhatis= lib/libohash \
+ lib/libsqlite3 \
+ lib/libmandoc \
+ usr.bin/mandoc
+${_bt}-usr.bin/mandoc: ${_bt}-lib/libohash ${_bt}-lib/libsqlite3
+.else
+_makewhatis=usr.bin/makewhatis
+.endif
+
# Rebuild up-to-date libmd for xinstall
${_bt}-usr.bin/xinstall: ${_bt}-lib/libmd
@@ -1383,7 +1393,7 @@ bootstrap-tools: .PHONY
${_awk} \
${_cat} \
usr.bin/lorder \
- usr.bin/makewhatis \
+ ${_makewhatis} \
usr.bin/rpcgen \
${_sed} \
${_yacc} \
Modified: head/share/mk/src.opts.mk
==============================================================================
--- head/share/mk/src.opts.mk Sat May 30 17:29:51 2015 (r283776)
+++ head/share/mk/src.opts.mk Sat May 30 17:41:37 2015 (r283777)
@@ -126,6 +126,7 @@ __DEFAULT_YES_OPTIONS = \
MAIL \
MAILWRAPPER \
MAKE \
+ MANDOCDB \
NDIS \
NETCAT \
NETGRAPH \
Added: head/tools/build/options/WITHOUT_MANDOCDB
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/tools/build/options/WITHOUT_MANDOCDB Sat May 30 17:41:37 2015 (r283777)
@@ -0,0 +1,6 @@
+.\" $FreeBSD$
+Use the
+.Xr mandoc 1
+version of
+.Xr makewhatis 8
+database and utilities.
Modified: head/usr.bin/Makefile
==============================================================================
--- head/usr.bin/Makefile Sat May 30 17:29:51 2015 (r283776)
+++ head/usr.bin/Makefile Sat May 30 17:41:37 2015 (r283777)
@@ -317,7 +317,9 @@ SUBDIR+= bmake
.if ${MK_MAN_UTILS} != "no"
SUBDIR+= catman
+.if ${MK_MANDOCDB} == "no"
_makewhatis= makewhatis
+.endif
_man= man
.endif
Modified: head/usr.bin/man/Makefile
==============================================================================
--- head/usr.bin/man/Makefile Sat May 30 17:29:51 2015 (r283776)
+++ head/usr.bin/man/Makefile Sat May 30 17:41:37 2015 (r283777)
@@ -1,11 +1,17 @@
# $FreeBSD$
+.include <src.opts.mk>
+
SCRIPTS= man.sh
-LINKS= ${BINDIR}/man ${BINDIR}/apropos \
- ${BINDIR}/man ${BINDIR}/manpath \
- ${BINDIR}/man ${BINDIR}/whatis
+LINKS= ${BINDIR}/man ${BINDIR}/manpath
-MAN= man.1 manpath.1 apropos.1 man.conf.5
+MAN= man.1 manpath.1 man.conf.5
+
+.if ${MK_MANDOCDB} == no
+LINKS+= ${BINDIR}/man ${BINDIR}/apropos \
+ ${BINDIR}/man ${BINDIR}/whatis
+MAN+= apropos.1
MLINKS= apropos.1 whatis.1
+.endif
.include <bsd.prog.mk>
Modified: head/usr.bin/mandoc/Makefile
==============================================================================
--- head/usr.bin/mandoc/Makefile Sat May 30 17:29:51 2015 (r283776)
+++ head/usr.bin/mandoc/Makefile Sat May 30 17:41:37 2015 (r283777)
@@ -1,5 +1,7 @@
# $FreeBSD$
+.include <src.opts.mk>
+
MDOCMLDIR= ${.CURDIR}/../../contrib/mdocml
.PATH: ${MDOCMLDIR}
@@ -7,7 +9,14 @@ PROG= mandoc
FILES= example.style.css style.css
FILESDIR= ${SHAREDIR}/mdocml
MAN= mandoc.1 eqn.7 mandoc_char.7 tbl.7 man.7 mdoc.7 # roff.7
-MLINKS= mandoc.1 mdocml.1
+MLINKS= mandoc.1 mdocml.1
+.if ${MK_MANDOCDB} != no
+MAN+= apropos.1 makewhatis.8
+MLINKS+= apropos.1 whatis.1
+LINKS= ${BINDIR}/mandoc ${BINDIR}/whatis \
+ ${BINDIR}/mandoc ${BINDIR}/makewhatis \
+ ${BINDIR}/mandoc ${BINDIR}/apropos
+.endif
LIBMAN_SRCS= man.c \
man_hash.c \
More information about the svn-src-head
mailing list