Recognize DragonFlyBSD. From Jan Stary <hans@stare.cz>. Bump version.diff -r1.30 -r1.31 pkgsrc/textproc/mdoclint/Makefile
(wiz)
@@ -1,16 +1,16 @@ | @@ -1,16 +1,16 @@ | |||
1 | # $NetBSD: Makefile,v 1.30 2013/07/30 19:09:00 wiz Exp $ | 1 | # $NetBSD: Makefile,v 1.31 2013/08/21 11:22:15 wiz Exp $ | |
2 | 2 | |||
3 | DISTNAME= mdoclint-1.22 | 3 | DISTNAME= mdoclint-1.23 | |
4 | CATEGORIES= textproc | 4 | CATEGORIES= textproc | |
5 | MASTER_SITES= # none | 5 | MASTER_SITES= # none | |
6 | DISTFILES= # none | 6 | DISTFILES= # none | |
7 | 7 | |||
8 | OWNER= wiz@NetBSD.org | 8 | OWNER= wiz@NetBSD.org | |
9 | #HOMEPAGE= # | 9 | #HOMEPAGE= # | |
10 | COMMENT= Tool for verifying man pages | 10 | COMMENT= Tool for verifying man pages | |
11 | LICENSE= 2-clause-bsd | 11 | LICENSE= 2-clause-bsd | |
12 | 12 | |||
13 | INSTALLATION_DIRS= bin ${PKGMANDIR}/man1 | 13 | INSTALLATION_DIRS= bin ${PKGMANDIR}/man1 | |
14 | 14 | |||
15 | CONFLICTS= mdocml<1.6.9 | 15 | CONFLICTS= mdocml<1.6.9 | |
16 | 16 |
@@ -1,17 +1,17 @@ | @@ -1,17 +1,17 @@ | |||
1 | #!@PERL5@ | 1 | #!@PERL5@ | |
2 | # | 2 | # | |
3 | # $OpenBSD: mdoclint,v 1.14 2009/04/13 12:40:05 espie Exp $ | 3 | # $OpenBSD: mdoclint,v 1.14 2009/04/13 12:40:05 espie Exp $ | |
4 | # $NetBSD: mdoclint,v 1.40 2013/08/05 10:08:25 wiz Exp $ | 4 | # $NetBSD: mdoclint,v 1.41 2013/08/21 11:22:15 wiz Exp $ | |
5 | # | 5 | # | |
6 | # Copyright (c) 2001-2013 Thomas Klausner | 6 | # Copyright (c) 2001-2013 Thomas Klausner | |
7 | # All rights reserved. | 7 | # All rights reserved. | |
8 | # | 8 | # | |
9 | # Redistribution and use in source and binary forms, with or without | 9 | # Redistribution and use in source and binary forms, with or without | |
10 | # modification, are permitted provided that the following conditions | 10 | # modification, are permitted provided that the following conditions | |
11 | # are met: | 11 | # are met: | |
12 | # 1. Redistributions of source code must retain the above copyright | 12 | # 1. Redistributions of source code must retain the above copyright | |
13 | # notice, this list of conditions and the following disclaimer. | 13 | # notice, this list of conditions and the following disclaimer. | |
14 | # 2. Redistributions in binary form must reproduce the above copyright | 14 | # 2. Redistributions in binary form must reproduce the above copyright | |
15 | # notice, this list of conditions and the following disclaimer in the | 15 | # notice, this list of conditions and the following disclaimer in the | |
16 | # documentation and/or other materials provided with the distribution. | 16 | # documentation and/or other materials provided with the distribution. | |
17 | # | 17 | # | |
@@ -72,37 +72,38 @@ usage: mdoclint [-$options] file ... | @@ -72,37 +72,38 @@ usage: mdoclint [-$options] file ... | |||
72 | -H warn about characters that produce problems in HTML output | 72 | -H warn about characters that produce problems in HTML output | |
73 | -h display this help text | 73 | -h display this help text | |
74 | -l warn about unknown libraries | 74 | -l warn about unknown libraries | |
75 | -m warn about man pages that are not in mdoc(7) format | 75 | -m warn about man pages that are not in mdoc(7) format | |
76 | -n warn about .Nd's ending in '.' | 76 | -n warn about .Nd's ending in '.' | |
77 | -o warn about non-empty .Os strings | 77 | -o warn about non-empty .Os strings | |
78 | -P warn about paragraph problems | 78 | -P warn about paragraph problems | |
79 | -p warn about punctuation problems | 79 | -p warn about punctuation problems | |
80 | -r warn about missing RCS Id | 80 | -r warn about missing RCS Id | |
81 | -S warn about any .Sh weirdness | 81 | -S warn about any .Sh weirdness | |
82 | -s warn about whitespace problems | 82 | -s warn about whitespace problems | |
83 | -v verbose output | 83 | -v verbose output | |
84 | -w show section header in warnings | 84 | -w show section header in warnings | |
85 | -X warn about explicit mentions of FreeBSD, NetBSD, or OpenBSD | 85 | -X warn about explicit mentions of the *BSD system names | |
86 | -x warn about cross-references with missing targets | 86 | -x warn about cross-references with missing targets | |
87 | Default is $default if no flag is specified. | 87 | Default is $default if no flag is specified. | |
88 | EOF | 88 | EOF | |
89 | exit(0); | 89 | exit(0); | |
90 | } | 90 | } | |
91 | 91 | |||
92 | 92 | |||
93 | my %short = ( | 93 | my %short = ( | |
94 | "Free" => ".Fx", | 94 | "Free" => ".Fx", | |
95 | "Net" => ".Nx", | 95 | "Net" => ".Nx", | |
96 | "DragonFly" => ".Dx", | |||
96 | "Open" => ".Ox" | 97 | "Open" => ".Ox" | |
97 | ); | 98 | ); | |
98 | 99 | |||
99 | my %libraries = ( | 100 | my %libraries = ( | |
100 | "libarchive" => 1, | 101 | "libarchive" => 1, | |
101 | "libarm" => 1, | 102 | "libarm" => 1, | |
102 | "libarm32" => 1, | 103 | "libarm32" => 1, | |
103 | "libbluetooth" => 1, | 104 | "libbluetooth" => 1, | |
104 | "libc" => 1, | 105 | "libc" => 1, | |
105 | "libcdk" => 1, | 106 | "libcdk" => 1, | |
106 | "libcompat" => 1, | 107 | "libcompat" => 1, | |
107 | "libcrypt" => 1, | 108 | "libcrypt" => 1, | |
108 | "libcurses" => 1, | 109 | "libcurses" => 1, | |
@@ -513,35 +514,36 @@ sub process_line | @@ -513,35 +514,36 @@ sub process_line | |||
513 | if (OPENBSD) { | 514 | if (OPENBSD) { | |
514 | if (/^(?:[<>])/o or /[^\\][<>]/o) { | 515 | if (/^(?:[<>])/o or /[^\\][<>]/o) { | |
515 | $s->warning("use \*(Lt \*(Gt (or .Aq) ", | 516 | $s->warning("use \*(Lt \*(Gt (or .Aq) ", | |
516 | "instead of < >: `$_'") if $opt_H; | 517 | "instead of < >: `$_'") if $opt_H; | |
517 | } | 518 | } | |
518 | } | 519 | } | |
519 | if (NETBSD) { | 520 | if (NETBSD) { | |
520 | if (/^(?:[<>&])/o or /[^\\][<>&]/o) { | 521 | if (/^(?:[<>&])/o or /[^\\][<>&]/o) { | |
521 | $s->warning("use \*[Lt] \*[Gt] (or .Aq) \*[Am] ", | 522 | $s->warning("use \*[Lt] \*[Gt] (or .Aq) \*[Am] ", | |
522 | "instead of < > &: `$_'") if $opt_H; | 523 | "instead of < > &: `$_'") if $opt_H; | |
523 | } | 524 | } | |
524 | } | 525 | } | |
525 | 526 | |||
526 | if (/\b(Free|Net|Open)BSD\b/o | 527 | if (/\b(Free|Net|DragonFly|Open)BSD\b/o | |
527 | and not /\b(?:www|ftp)\.(?:Free|Net|Open)BSD\.org\b/o | 528 | and not /\b(?:www|ftp)\.(?:Free|Net|DragonFly|Open)BSD\.org\b/o | |
528 | and not /\bOpenBSD\::.*3p\b/o | 529 | and not /\bOpenBSD\::.*3p\b/o | |
529 | and not /\/pub\/OpenBSD\//o | 530 | and not /\/pub\/OpenBSD\//o | |
530 | and not /\@(?:Free|Net|Open)BSD\.(?i:org)\b/o) { | 531 | and not /\@(?:Free|Net|Open)BSD\.(?i:org)\b/o) { | |
531 | $s->warning("verbose mention of `$1BSD' instead of " | 532 | $s->warning("verbose mention of `$1BSD' instead of " | |
532 | . "`$short{$1}': `$_'") if $opt_X; | 533 | . "`$short{$1}': `$_'") if $opt_X; | |
533 | } | 534 | } | |
534 | if (/^\./o and (/Bx (Open)/o or /Bx (Free)/o or /Bx (Net)/o)) { | 535 | if (/^\./o and (/Bx (Open)/o or /Bx (Free)/o | |
536 | or /Bx (DragonFly)/o or /Bx (Net)/o)) { | |||
535 | $s->warning("`.Bx $1' found -- use $short{$1} instead") | 537 | $s->warning("`.Bx $1' found -- use $short{$1} instead") | |
536 | if $opt_X; | 538 | if $opt_X; | |
537 | } | 539 | } | |
538 | if (/^\.Lb\s+(\S+)/o) { | 540 | if (/^\.Lb\s+(\S+)/o) { | |
539 | if (not $libraries{$1}) { | 541 | if (not $libraries{$1}) { | |
540 | $s->warning("Unknown library `$1' used as Lb argument") if $opt_l; | 542 | $s->warning("Unknown library `$1' used as Lb argument") if $opt_l; | |
541 | } | 543 | } | |
542 | } | 544 | } | |
543 | if (/^\.Os\s+(.+)/o) { | 545 | if (/^\.Os\s+(.+)/o) { | |
544 | $s->warning(".Os used with argument `$1'") if $opt_o; | 546 | $s->warning(".Os used with argument `$1'") if $opt_o; | |
545 | } | 547 | } | |
546 | 548 | |||
547 | if (/^\.Nd.*\.$/o) { | 549 | if (/^\.Nd.*\.$/o) { |
@@ -1,41 +1,41 @@ | @@ -1,41 +1,41 @@ | |||
1 | .\" $OpenBSD: mdoclint.1,v 1.7 2009/04/13 19:06:38 jmc Exp $ | 1 | .\" $OpenBSD: mdoclint.1,v 1.7 2009/04/13 19:06:38 jmc Exp $ | |
2 | .\" $NetBSD: mdoclint.1,v 1.12 2013/08/05 07:37:14 wiz Exp $ | 2 | .\" $NetBSD: mdoclint.1,v 1.13 2013/08/21 11:22:15 wiz Exp $ | |
3 | .\" | 3 | .\" | |
4 | .\" Copyright (c) 2001-2013 Thomas Klausner | 4 | .\" Copyright (c) 2001-2013 Thomas Klausner | |
5 | .\" All rights reserved. | 5 | .\" All rights reserved. | |
6 | .\" | 6 | .\" | |
7 | .\" Redistribution and use in source and binary forms, with or without | 7 | .\" Redistribution and use in source and binary forms, with or without | |
8 | .\" modification, are permitted provided that the following conditions | 8 | .\" modification, are permitted provided that the following conditions | |
9 | .\" are met: | 9 | .\" are met: | |
10 | .\" 1. Redistributions of source code must retain the above copyright | 10 | .\" 1. Redistributions of source code must retain the above copyright | |
11 | .\" notice, this list of conditions and the following disclaimer. | 11 | .\" notice, this list of conditions and the following disclaimer. | |
12 | .\" 2. Redistributions in binary form must reproduce the above copyright | 12 | .\" 2. Redistributions in binary form must reproduce the above copyright | |
13 | .\" notice, this list of conditions and the following disclaimer in the | 13 | .\" notice, this list of conditions and the following disclaimer in the | |
14 | .\" documentation and/or other materials provided with the distribution. | 14 | .\" documentation and/or other materials provided with the distribution. | |
15 | .\" | 15 | .\" | |
16 | .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR, THOMAS KLAUSNER, | 16 | .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR, THOMAS KLAUSNER, | |
17 | .\" ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED | 17 | .\" ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED | |
18 | .\" TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR | 18 | .\" TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR | |
19 | .\" PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS | 19 | .\" PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS | |
20 | .\" BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR | 20 | .\" BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR | |
21 | .\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF | 21 | .\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF | |
22 | .\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS | 22 | .\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS | |
23 | .\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN | 23 | .\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN | |
24 | .\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) | 24 | .\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) | |
25 | .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE | 25 | .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE | |
26 | .\" POSSIBILITY OF SUCH DAMAGE. | 26 | .\" POSSIBILITY OF SUCH DAMAGE. | |
27 | .\" | 27 | .\" | |
28 | .Dd July 30, 2013 | 28 | .Dd August 21, 2013 | |
29 | .Dt MDOCLINT 1 | 29 | .Dt MDOCLINT 1 | |
30 | .Os | 30 | .Os | |
31 | .Sh NAME | 31 | .Sh NAME | |
32 | .Nm mdoclint | 32 | .Nm mdoclint | |
33 | .Nd man page verifier | 33 | .Nd man page verifier | |
34 | .Sh SYNOPSIS | 34 | .Sh SYNOPSIS | |
35 | .Nm | 35 | .Nm | |
36 | .Op Fl AaDdeFfHhlmnoPprSsvwXx | 36 | .Op Fl AaDdeFfHhlmnoPprSsvwXx | |
37 | .Ar | 37 | .Ar | |
38 | .Sh DESCRIPTION | 38 | .Sh DESCRIPTION | |
39 | .Nm | 39 | .Nm | |
40 | is a man page verifier. | 40 | is a man page verifier. | |
41 | It tries to automatically find as many common | 41 | It tries to automatically find as many common | |
@@ -119,32 +119,34 @@ wrong order (see | @@ -119,32 +119,34 @@ wrong order (see | |||
119 | .Xr mdoc 7 ) . | 119 | .Xr mdoc 7 ) . | |
120 | .It Fl s | 120 | .It Fl s | |
121 | Warn about superfluous whitespace at the end of line. | 121 | Warn about superfluous whitespace at the end of line. | |
122 | .It Fl v | 122 | .It Fl v | |
123 | Verbose output. | 123 | Verbose output. | |
124 | .It Fl w | 124 | .It Fl w | |
125 | Display the section name, | 125 | Display the section name, | |
126 | in addition to the relevant line number, | 126 | in addition to the relevant line number, | |
127 | in warnings. | 127 | in warnings. | |
128 | .It Fl X | 128 | .It Fl X | |
129 | Warn about explicit mentions of the words | 129 | Warn about explicit mentions of the words | |
130 | .Dq FreeBSD , | 130 | .Dq FreeBSD , | |
131 | .Dq NetBSD , | 131 | .Dq NetBSD , | |
132 | .Dq DragonFlyBSD , | |||
132 | and | 133 | and | |
133 | .Dq OpenBSD , | 134 | .Dq OpenBSD , | |
134 | which should be replaced by .Fx, .Nx, and .Ox respectively. | 135 | which should be replaced by .Fx, .Nx, .Dx, and .Ox respectively. | |
135 | Also notices occurrences of | 136 | Also notices occurrences of | |
136 | .Dq \&.Bx Free , | 137 | .Dq \&.Bx Free , | |
137 | .Dq \&.Bx Net , | 138 | .Dq \&.Bx Net , | |
139 | .Dq \&.Bx DragonFly , | |||
138 | and | 140 | and | |
139 | .Dq \&.Bx Open , | 141 | .Dq \&.Bx Open , | |
140 | for which the same applies. | 142 | for which the same applies. | |
141 | .It Fl x | 143 | .It Fl x | |
142 | Warn about cross-references whose target is missing, cross-references | 144 | Warn about cross-references whose target is missing, cross-references | |
143 | to itself, or plain bogus cross-references. | 145 | to itself, or plain bogus cross-references. | |
144 | .Pp | 146 | .Pp | |
145 | For | 147 | For | |
146 | .Dq .Xr name X , | 148 | .Dq .Xr name X , | |
147 | the following files are checked: | 149 | the following files are checked: | |
148 | .Pa /usr/share/man/manX/name.X , | 150 | .Pa /usr/share/man/manX/name.X , | |
149 | .Pa /usr/share/man/manX/`uname -m`/name.X , | 151 | .Pa /usr/share/man/manX/`uname -m`/name.X , | |
150 | .Pa /usr/X11R7/man/manX/name.X , | 152 | .Pa /usr/X11R7/man/manX/name.X , |