Make it easier for the Guidebook to find macros.
* doc/Guidebook.mn: Make the Guidebook buildable from the top of the
source tree, not just inside the "doc" directory. Try to load its
"nh" macro package from the current working directory and from "doc".
* doc/tmac.nh: Allocate new register `nH` to the purpose of detecting
multiple loads, and skip file content if detected. This is the 1970s
nroff form of an "#include guard". groff's "an-ext.tmac" uses the
same technique for portability.
Also I removed a tab character. Per the groff Texinfo manual:
One possibly irritating idiosyncrasy is that tabs should not be
used to vertically align comments in the source document. Tab
characters are not treated as separators between a request name and
its first argument, nor between arguments.
Here's an example of how one groff macro package works around the
problem.
$ sed -n '402,406p' contrib/mm/m.tmac
.ds LetCN CONFIDENTIAL\" Confidential default
.ds LetSA To Whom It May Concern:\" Salutation default
.ds LetAT ATTENTION:\" Attention string
.ds LetSJ SUBJECT:\" Subject string
.ds LetRN In reference to:\" Reference string
This commit is contained in:
@@ -31,7 +31,8 @@
|
||||
.lt 70n
|
||||
.\}
|
||||
.
|
||||
.so tmac.nh \" extra macros which aren't in tmac.n
|
||||
.so tmac.nh \" extra macros which aren't in tmac.n
|
||||
.if !\n(nH .so doc/tmac.nh
|
||||
.
|
||||
.\" building Guidebook.txt doesn't have CR font available; groff 1.23 issues
|
||||
.\" a warning each time any font can't be loaded; earlier versions silently
|
||||
|
||||
@@ -8,6 +8,10 @@
|
||||
.\" cluttered as their number increased. It now uses the '.so' directive
|
||||
.\" to include this file. (tmac.n is passed to 'roff on the command line.)
|
||||
.
|
||||
.\" Protect against being sourced twice.
|
||||
.nr nH +1
|
||||
.if \n(nH>1 .nx
|
||||
.
|
||||
.\" labeled paragraph start
|
||||
.\" .PS word
|
||||
.\" set the width for the label column
|
||||
|
||||
Reference in New Issue
Block a user