aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBill Fenner <fenner@FreeBSD.org>1999-02-18 16:54:24 +0000
committerBill Fenner <fenner@FreeBSD.org>1999-02-18 16:54:24 +0000
commit1a8f70b737615a1d33d3a0b62f00dd096396eaf3 (patch)
treebe855ba5670aeb5617007241469578831ef571bd
parente68a8d49724071e84d57bd421c81c6f0ab7b9be0 (diff)
downloadsrc-1a8f70b737615a1d33d3a0b62f00dd096396eaf3.tar.gz
src-1a8f70b737615a1d33d3a0b62f00dd096396eaf3.zip
Make .Os behave as defined (unrecognized arguments displayed as given).
Add a warning for unknown BSD versions. Make ".Os FreeBSD" work without a warning (fix bug in previous commit).
Notes
Notes: svn path=/head/; revision=44116
-rw-r--r--contrib/groff/tmac/doc-common20
1 files changed, 8 insertions, 12 deletions
diff --git a/contrib/groff/tmac/doc-common b/contrib/groff/tmac/doc-common
index 4251a9678142..1e8724fc5a58 100644
--- a/contrib/groff/tmac/doc-common
+++ b/contrib/groff/tmac/doc-common
@@ -201,12 +201,7 @@
.\" .ds dD \s+4\f(CODRAFT\fP\s-4\ \ \-\-\ \ \\*(dD\ \ \-\-\ \ \s+4\f(CODRAFT\s-4
.de Os
.ds oS Null
-.if "\\$1"" \{\
-. ds oS BSD
-.\}
-.if "\\$2"" \{\
-. ds aa Non-Null
-.\}
+.if "\\$1"" .ds oS BSD
.if "\\$1"ATT" \{\
. ds oS AT&T
. if "\\$2"" .as oS \0UNIX
@@ -230,11 +225,11 @@
. if "\\$2"4.3t" .ds oS 4.3-Tahoe Berkeley Distribution
. if "\\$2"4.3r" .ds oS 4.3-Reno Berkeley Distribution
. if "\\$2"4.4" .ds oS 4.4BSD
+. if "\\*(oS"Null" .tm Unknown BSD version ``\\$2'' at line \\n(c.
.\}
.if "\\$1"FreeBSD" \{\
-. ie "\\$2"2" .ds oS FreeBSD 2.0
-. el .ds oS FreeBSD \\$2
-. ie \\n(.$==0 \c
+. if "\\$2"2" .ds oS FreeBSD 2.0
+. ie \\n(.$==1 \c
. el .ie "\\$2"2" \c
. el .ie "\\$2"2.0" \c
. el .ie "\\$2"2.0.5" \c
@@ -252,9 +247,10 @@
. el .ie "\\$2"4.0" \c
. el .tm Unknown FreeBSD version ``\\$2'' at line \\n(c.
.\}
-.if "\\*(oS"Null" .ds oS \0\\$1
-.if "\\*(aa"Non-Null" .as oS \0\\$2
-.rm aa
+.if "\\*(oS"Null" \{\
+. ds oS \&\\$1
+. if !"\\$2"" .as oS \& \\$2
+.\}
..
.de Dd
.if !"\\*(dD"" .nr gX 1