Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src Rework /usr/share/doc.
details: https://anonhg.NetBSD.org/src/rev/74bab0fc83d3
branches: trunk
changeset: 330332:74bab0fc83d3
user: dholland <dholland%NetBSD.org@localhost>
date: Sat Jul 05 19:22:02 2014 +0000
description:
Rework /usr/share/doc.
Update the <bsd.doc.mk> infrastructure, and update the docs to match
the new infrastructure.
- Build and install text, ps, pdf, and/or html, not roff sources.
- Don't wire the chapter numbers into the build system, or use them in
the installed pathnames. This didn't matter much when the docs were a
museum, but now that we're theoretically going to start maintaining
them again, we're going to add and remove documents periodically and
having the chapter numbers baked in creates a lot of thrashing for no
purpose.
- Specify the document name explicitly, rather than implicitly in a
path. Use this name (instead of other random strings) as the name
of the installed files.
- Specify the document section, which is the subdirectory of
/usr/share/doc to install into.
- Allow multiple subdocuments. (That is, multiple documents in one
output directory.)
- Enumerate the .png files groff emits along with html so they can be
installed.
- Remove assorted hand-rolled rules for running roff and roff widgetry
and add enough variable settings to make these unnecessary. This
includes support for
- explicit use of soelim
- refer
- tbl
- pic
- eqn
- Forcibly apply at least minimal amounts of sanity to certain
autogenerated roff files.
- Don't exclude USD.doc, SMM.doc, and PSD.doc directories from the
build, as they now actually do stuff.
Note: currently we can't generate pdf. This turns out to be a
nontrivial problem with no immediate solution forthcoming. So for now,
as a workaround, install compressed .ps as the printable form.
diffstat:
bin/csh/USD.doc/Makefile | 12 +-
bin/sh/USD.doc/Makefile | 16 +-
bin/sh/USD.doc/referargs | 8 +
external/bsd/nvi/docs/USD.doc/edit/Makefile | 15 +-
external/bsd/nvi/docs/USD.doc/exref/Makefile | 26 +-
external/bsd/nvi/docs/USD.doc/vi.ref/Makefile | 28 +--
external/bsd/nvi/docs/USD.doc/vitut/Makefile | 35 +-
games/rogue/Makefile | 4 +-
games/rogue/USD.doc/Makefile | 9 +-
games/trek/Makefile | 4 +-
games/trek/USD.doc/Makefile | 9 +-
lib/libcurses/PSD.doc/Makefile | 22 +-
sbin/fsck_ffs/Makefile | 4 +-
sbin/fsck_ffs/SMM.doc/Makefile | 6 +-
share/doc/Makefile | 4 +-
share/doc/psd/05.sysman/Makefile | 21 +-
share/doc/psd/20.ipctut/Makefile | 15 +-
share/doc/psd/21.ipc/Makefile | 10 +-
share/doc/psd/Makefile | 15 +-
share/doc/smm/01.setup/Makefile | 21 +-
share/doc/smm/04.quotas/Makefile | 5 +-
share/doc/smm/05.fastfs/Makefile | 16 +-
share/doc/smm/06.nfs/Makefile | 5 +-
share/doc/smm/17.password/Makefile | 6 +-
share/doc/smm/18.net/Makefile | 11 +-
share/doc/smm/Makefile | 23 +-
share/doc/smm/config/Makefile | 12 +-
share/doc/usd/01.begin/Makefile | 9 +-
share/doc/usd/17.msmacros/Makefile | 15 +-
share/doc/usd/18.msdiffs/Makefile | 6 +-
share/doc/usd/19.memacros/Makefile | 5 +-
share/doc/usd/20.meref/Makefile | 5 +-
share/doc/usd/Makefile | 24 +-
share/mk/bsd.doc.mk | 245 ++++++++++++++++++++-----
share/mk/bsd.own.mk | 6 +-
usr.bin/gprof/Makefile | 6 +-
usr.bin/gprof/PSD.doc/Makefile | 19 +-
usr.bin/m4/PSD.doc/Makefile | 8 +-
usr.bin/mail/Makefile | 6 +-
usr.bin/mail/USD.doc/Makefile | 11 +-
usr.bin/make/Makefile | 4 +-
usr.bin/make/PSD.doc/Makefile | 6 +-
usr.sbin/lpr/Makefile | 5 +-
usr.sbin/lpr/SMM.doc/Makefile | 11 +-
usr.sbin/timed/Makefile | 5 +-
usr.sbin/timed/SMM.doc/timed/Makefile | 17 +-
usr.sbin/timed/SMM.doc/timedop/Makefile | 6 +-
47 files changed, 460 insertions(+), 321 deletions(-)
diffs (truncated from 1368 to 300 lines):
diff -r ccd8fb3895ee -r 74bab0fc83d3 bin/csh/USD.doc/Makefile
--- a/bin/csh/USD.doc/Makefile Sat Jul 05 17:39:21 2014 +0000
+++ b/bin/csh/USD.doc/Makefile Sat Jul 05 19:22:02 2014 +0000
@@ -1,12 +1,12 @@
-# $NetBSD: Makefile,v 1.7 2007/10/18 18:26:31 tls Exp $
+# $NetBSD: Makefile,v 1.8 2014/07/05 19:22:02 dholland Exp $
# @(#)Makefile 8.1 (Berkeley) 8/14/93
-DIR= usd/04.csh
+SECTION=usd
+ARTICLE=csh
SRCS= tabs csh.1 csh.2 csh.3 csh.4 csh.ap csh.g
MACROS= -ms
-
-paper.ps: ${SRCS}
- ${TOOL_SOELIM} -I${.CURDIR} ${.ALLSRC} | \
- ${TOOL_ROFF_PS} ${MACROS} > ${.TARGET}
+EXTRAHTMLFILES=\
+ csh1.png csh2.png csh3.png csh4.png csh5.png csh6.png csh7.png \
+ csh8.png csh9.png
.include <bsd.doc.mk>
diff -r ccd8fb3895ee -r 74bab0fc83d3 bin/sh/USD.doc/Makefile
--- a/bin/sh/USD.doc/Makefile Sat Jul 05 17:39:21 2014 +0000
+++ b/bin/sh/USD.doc/Makefile Sat Jul 05 19:22:02 2014 +0000
@@ -1,12 +1,12 @@
-# $NetBSD: Makefile,v 1.1 2010/08/22 01:58:16 perry Exp $
+# $NetBSD: Makefile,v 1.2 2014/07/05 19:22:02 dholland Exp $
# @(#)Makefile 8.1 (Berkeley) 8/14/93
-DIR= usd/03.shell
-SRCS= Rv7man t.mac t1 t2 t3 t4
-MACROS= -ms
-
-paper.ps: ${SRCS}
- ${TOOL_REFER} -e -p ${SRCS} | \
- ${TOOL_ROFF_PS} ${MACROS} > ${.TARGET}
+SECTION=usd
+ARTICLE=shell
+SRCS= referargs t.mac t1 t2 t3 t4
+MACROS=-ms
+ROFF_REFER=yes
+#REFER_ARGS=-e -p Rv7man
+EXTRAHTMLFILES=shell1.png shell2.png shell3.png shell4.png shell5.png
.include <bsd.doc.mk>
diff -r ccd8fb3895ee -r 74bab0fc83d3 bin/sh/USD.doc/referargs
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/bin/sh/USD.doc/referargs Sat Jul 05 19:22:02 2014 +0000
@@ -0,0 +1,8 @@
+.\" $NetBSD: referargs,v 1.1 2014/07/05 19:22:02 dholland Exp $
+.\"
+.\" Arguments for refer; these were previously passed on the refer(1)
+.\" command line: -e -p Rv7man
+.R1
+accumulate
+database Rv7man
+.R2
diff -r ccd8fb3895ee -r 74bab0fc83d3 external/bsd/nvi/docs/USD.doc/edit/Makefile
--- a/external/bsd/nvi/docs/USD.doc/edit/Makefile Sat Jul 05 17:39:21 2014 +0000
+++ b/external/bsd/nvi/docs/USD.doc/edit/Makefile Sat Jul 05 19:22:02 2014 +0000
@@ -1,17 +1,18 @@
-# $NetBSD: Makefile,v 1.1 2013/11/22 16:00:45 christos Exp $
+# $NetBSD: Makefile,v 1.2 2014/07/05 19:22:02 dholland Exp $
#
# @(#)Makefile 8.1 (Berkeley) 6/8/93
.include "../../../Makefile.inc"
.PATH: ${DIST}/docs/edit
-DIR= usd/11.edit
+
+SECTION=usd
+ARTICLE=edit
SRCS= edittut.ms
MACROS= -ms
-
-all: paper.ps
+ROFF_TBL=yes
+EXTRAHTMLFILES=edit1.png edit2.png edit3.png
-paper.ps: ${SRCS}
- ${TOOL_TBL} ${.ALLSRC} | ${TOOL_ROFF_PS} ${MACROS} > ${.TARGET}
+.include <bsd.doc.mk>
# index for versatec is different from the one in edit.tut
# because the fonts are different and entries reference page
@@ -20,5 +21,3 @@
editvindex:
${TOOL_ROFF_RAW} ${MACROS} -n22 edit.vindex
-
-.include <bsd.doc.mk>
diff -r ccd8fb3895ee -r 74bab0fc83d3 external/bsd/nvi/docs/USD.doc/exref/Makefile
--- a/external/bsd/nvi/docs/USD.doc/exref/Makefile Sat Jul 05 17:39:21 2014 +0000
+++ b/external/bsd/nvi/docs/USD.doc/exref/Makefile Sat Jul 05 19:22:02 2014 +0000
@@ -1,21 +1,23 @@
-# $NetBSD: Makefile,v 1.1 2013/11/22 16:00:45 christos Exp $
+# $NetBSD: Makefile,v 1.2 2014/07/05 19:22:02 dholland Exp $
#
# @(#)Makefile 8.8 (Berkeley) 10/10/96
.include "../../../Makefile.inc"
.PATH: ${DIST}/docs/exref
-DIR= usd/12.ex
-SRCS= ex.rm ex.summary
+SECTION= usd
+ARTICLE= ex
+SUBARTICLES= reference summary
+SRCS.reference= ex.rm
+SRCS.summary= ex.summary
MACROS= -ms
-CLEANFILES= summary.ps
-
-all: paper.ps summary.ps
-
-paper.ps: ex.rm
- ${TOOL_TBL} ${.ALLSRC} | ${TOOL_ROFF_PS} ${MACROS} > ${.TARGET}
-
-summary.ps: ex.summary
- ${TOOL_TBL} ${.ALLSRC} | ${TOOL_ROFF_PS} ${MACROS} > ${.TARGET}
+ROFF_TBL= yes
+EXTRAHTMLFILES= \
+ ex1.png ex2.png ex3.png ex4.png ex5.png \
+ ex6.png ex7.png ex8.png ex9.png ex10.png \
+ ex11.png ex12.png ex13.png ex14.png ex15.png \
+ ex16.png ex17.png ex18.png ex19.png ex20.png \
+ ex21.png ex22.png ex23.png ex24.png ex25.png \
+ ex26.png ex27.png
.include <bsd.doc.mk>
diff -r ccd8fb3895ee -r 74bab0fc83d3 external/bsd/nvi/docs/USD.doc/vi.ref/Makefile
--- a/external/bsd/nvi/docs/USD.doc/vi.ref/Makefile Sat Jul 05 17:39:21 2014 +0000
+++ b/external/bsd/nvi/docs/USD.doc/vi.ref/Makefile Sat Jul 05 19:22:02 2014 +0000
@@ -1,26 +1,19 @@
-# $NetBSD: Makefile,v 1.1 2013/11/22 16:00:45 christos Exp $
+# $NetBSD: Makefile,v 1.2 2014/07/05 19:22:02 dholland Exp $
#
# @(#)Makefile 8.20 (Berkeley) 8/18/96
-DIR= usd/13.viref
-SRCS= vi.ref ex.cmd.roff set.opt.roff vi.cmd.roff ref.so
+SECTION= usd
+ARTICLE= viref
+SRCS= vi.ref
+DEPSRCS= ex.cmd.roff set.opt.roff vi.cmd.roff ref.so index.so
MACROS= -me
-CLEANFILES+= vi.ref.txt vi.ref.ps index index.so
-
-all: vi.ref.txt vi.ref.ps
+ROFF_TBL= yes
+CLEANFILES+= index index.so
-vi.ref.txt: vi.ref index.so
- ${TOOL_SOELIM} vi.ref | ${TOOL_TBL} | ${TOOL_ROFF_ASCII} ${MACROS} > $@
- rm -f index
- chmod 444 $@
+.include <bsd.doc.mk>
-vi.ref.ps: vi.ref index.so
- ${TOOL_SOELIM} vi.ref | ${TOOL_TBL} | ${TOOL_ROFF_PS} ${MACROS} > $@
- rm -f index
- chmod 444 $@
-
+# index.so is generated.
index.so: vi.ref
- # Build index.so, side-effect of building the paper.
${TOOL_SOELIM} vi.ref | ${TOOL_TBL} | \
${TOOL_ROFF_PS} ${MACROS} > /dev/null
sed -e 's/MINUSSIGN/\\-/' \
@@ -30,6 +23,3 @@
sort -u '-t ' +0 -1 +1n | awk -f merge.awk | \
sed -e 's/__SPACE/ /g' > $@
rm -f index
- chmod 444 $@
-
-.include <bsd.doc.mk>
diff -r ccd8fb3895ee -r 74bab0fc83d3 external/bsd/nvi/docs/USD.doc/vitut/Makefile
--- a/external/bsd/nvi/docs/USD.doc/vitut/Makefile Sat Jul 05 17:39:21 2014 +0000
+++ b/external/bsd/nvi/docs/USD.doc/vitut/Makefile Sat Jul 05 19:22:02 2014 +0000
@@ -1,26 +1,25 @@
-# $NetBSD: Makefile,v 1.1 2013/11/22 16:00:45 christos Exp $
+# $NetBSD: Makefile,v 1.2 2014/07/05 19:22:03 dholland Exp $
#
# @(#)Makefile 8.7 (Berkeley) 8/18/96
.include "../../../Makefile.inc"
.PATH: ${DIST}/docs/vitut
-DIR= usd/12.vi
-SRCS= vi.in vi.chars
+
+SECTION= usd
+ARTICLE= vi
+SUBARTICLES= vitut summary
+SRCS.vitut= vi.in vi.chars
+SRCS.summary= vi.summary
+SRCS.viapwh= vi.apwh.ms
MACROS= -ms
-CLEANFILES+= vitut.ps summary.ps viapwh.ps
-
-all: vitut.ps summary.ps viapwh.ps
-
-vitut.ps: ${SRCS}
- ${TOOL_TBL} ${.ALLSRC} | ${TOOL_ROFF_PS} ${MACROS} > $@
- chmod 444 $@
-
-summary.ps: vi.summary
- ${TOOL_TBL} ${.ALLSRC} | ${TOOL_ROFF_PS} ${MACROS} > $@
- chmod 444 $@
-
-viapwh.ps: vi.apwh.ms
- ${TOOL_TBL} ${.ALLSRC} | ${TOOL_ROFF_PS} ${MACROS} > $@
- chmod 444 $@
+ROFF_TBL= yes
+EXTRAHTMLFILES= \
+ vi1.png vi2.png vi3.png vi4.png vi5.png \
+ vi6.png vi7.png vi8.png vi9.png vi10.png \
+ vi11.png vi12.png vi13.png vi14.png vi15.png \
+ vi16.png vi17.png vi18.png vi19.png vi20.png \
+ vi21.png vi22.png vi23.png vi24.png vi25.png \
+ vi26.png vi27.png vi28.png vi29.png vi30.png \
+ vi31.png vi32.png vi33.png
.include <bsd.doc.mk>
diff -r ccd8fb3895ee -r 74bab0fc83d3 games/rogue/Makefile
--- a/games/rogue/Makefile Sat Jul 05 17:39:21 2014 +0000
+++ b/games/rogue/Makefile Sat Jul 05 19:22:02 2014 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.18 2013/08/11 03:44:27 dholland Exp $
+# $NetBSD: Makefile,v 1.19 2014/07/05 19:22:03 dholland Exp $
# @(#)Makefile 8.1 (Berkeley) 5/31/93
PROG= rogue
@@ -12,9 +12,7 @@
SETGIDGAME=yes
MAN= rogue.6
-.if make(install)
SUBDIR+=USD.doc
-.endif
.include <bsd.prog.mk>
.include <bsd.subdir.mk>
diff -r ccd8fb3895ee -r 74bab0fc83d3 games/rogue/USD.doc/Makefile
--- a/games/rogue/USD.doc/Makefile Sat Jul 05 17:39:21 2014 +0000
+++ b/games/rogue/USD.doc/Makefile Sat Jul 05 19:22:02 2014 +0000
@@ -1,11 +1,10 @@
-# $NetBSD: Makefile,v 1.5 2013/02/17 12:17:40 jmcneill Exp $
+# $NetBSD: Makefile,v 1.6 2014/07/05 19:22:03 dholland Exp $
# @(#)Makefile 8.1 (Berkeley) 6/8/93
-DIR= usd/30.rogue
+SECTION=usd
+ARTICLE=rogue
SRCS= rogue.me
MACROS= -me
-
-paper.ps: ${SRCS}
- ${TOOL_TBL} ${SRCS} | ${TOOL_ROFF_PS} ${MACROS} > ${.TARGET}
+ROFF_TBL=yes
.include <bsd.doc.mk>
diff -r ccd8fb3895ee -r 74bab0fc83d3 games/trek/Makefile
--- a/games/trek/Makefile Sat Jul 05 17:39:21 2014 +0000
+++ b/games/trek/Makefile Sat Jul 05 19:22:02 2014 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.14 2011/08/16 11:28:18 christos Exp $
+# $NetBSD: Makefile,v 1.15 2014/07/05 19:22:03 dholland Exp $
# @(#)Makefile 8.1 (Berkeley) 5/31/93
PROG= trek
@@ -15,9 +15,7 @@
LDADD= -lm
HIDEGAME=hidegame
-.if make(install)
SUBDIR+=USD.doc
-.endif
COPTS.getpar.c += -Wno-format-nonliteral
diff -r ccd8fb3895ee -r 74bab0fc83d3 games/trek/USD.doc/Makefile
--- a/games/trek/USD.doc/Makefile Sat Jul 05 17:39:21 2014 +0000
+++ b/games/trek/USD.doc/Makefile Sat Jul 05 19:22:02 2014 +0000
@@ -1,11 +1,10 @@
-# $NetBSD: Makefile,v 1.4 2003/07/10 10:34:20 lukem Exp $
+# $NetBSD: Makefile,v 1.5 2014/07/05 19:22:03 dholland Exp $
# @(#)Makefile 8.1 (Berkeley) 6/8/93
-DIR= usd/31.trek
+SECTION=usd
+ARTICLE=trek
SRCS= trek.me
MACROS= -me
-
-paper.ps: ${SRCS}
- ${TOOL_TBL} ${SRCS} | ${TOOL_ROFF_PS} ${MACROS} > ${.TARGET}
+ROFF_TBL=yes
.include <bsd.doc.mk>
Home |
Main Index |
Thread Index |
Old Index