33d4a116a5f34afad5ccda4fe894da8acf90d07b
[metze/wireshark/wip.git] / doc / make-authors-format.pl
1 # Convert AUTHORS-SHORT file for use in man page and HTML documentation
2 # after processing through pod2man and pod2html.
3 #
4 # Must be called via perlnoutf.
5 #
6 # Copyright 2004 Graeme Hewson <ghewson@wormhole.me.uk>
7 #
8 # Wireshark - Network traffic analyzer
9 # By Gerald Combs <gerald@wireshark.org>
10 # Copyright 1998 Gerald Combs
11 #
12 # SPDX-License-Identifier: GPL-2.0-or-later
13 #
14
15 use strict;
16
17 print "=for html <pre>\n\n";
18 print "=for man .nf\n\n";
19
20 while (<>) {
21         printline();
22 }
23
24 print "\n=for html </pre>\n";
25 print "\n=for man .fi\n";
26
27 sub printline {
28         my $line = shift || $_;
29 #
30 # Translate UTF-8 characters to the E<> escapes handled by Pod::Man
31 # (and only those, since they're a subset of HTML entities)
32 #
33         $line =~ s/\xc3\x80/E<Agrave>/g;
34         $line =~ s/\xc3\x81/E<Aacute>/g;
35         $line =~ s/\xc3\x82/E<Acirc>/g;
36         $line =~ s/\xc3\x83/E<Atilde>/g;
37         $line =~ s/\xc3\x84/E<Auml>/g;
38         $line =~ s/\xc3\x85/E<Aring>/g;
39         $line =~ s/\xc3\x86/E<AElig>/g;
40         $line =~ s/\xc3\x87/E<Ccedil>/g;
41         $line =~ s/\xc3\x88/E<Egrave>/g;
42         $line =~ s/\xc3\x89/E<Eacute>/g;
43         $line =~ s/\xc3\x8a/E<Ecirc>/g;
44         $line =~ s/\xc3\x8b/E<Euml>/g;
45         $line =~ s/\xc3\x8c/E<Igrave>/g;
46         $line =~ s/\xc3\x8d/E<Iacute>/g;
47         $line =~ s/\xc3\x8e/E<Icirc>/g;
48         $line =~ s/\xc3\x8f/E<Iuml>/g;
49         $line =~ s/\xc3\x90/E<ETH>/g;
50         $line =~ s/\xc3\x91/E<Ntilde>/g;
51         $line =~ s/\xc3\x92/E<Ograve>/g;
52         $line =~ s/\xc3\x93/E<Oacute>/g;
53         $line =~ s/\xc3\x94/E<Ocirc>/g;
54         $line =~ s/\xc3\x95/E<Otilde>/g;
55         $line =~ s/\xc3\x96/E<Ouml>/g;
56         $line =~ s/\xc3\x98/E<Oslash>/g;
57         $line =~ s/\xc3\x99/E<Ugrave>/g;
58         $line =~ s/\xc3\x9a/E<Uacute>/g;
59         $line =~ s/\xc3\x9b/E<Ucirc>/g;
60         $line =~ s/\xc3\x9c/E<Uuml>/g;
61         $line =~ s/\xc3\x9d/E<Yacute>/g;
62         $line =~ s/\xc3\x9e/E<THORN>/g;
63         $line =~ s/\xc3\x9f/E<szlig>/g;
64         $line =~ s/\xc3\xa0/E<agrave>/g;
65         $line =~ s/\xc3\xa1/E<aacute>/g;
66         $line =~ s/\xc3\xa2/E<acirc>/g;
67         $line =~ s/\xc3\xa3/E<atilde>/g;
68         $line =~ s/\xc3\xa4/E<auml>/g;
69         $line =~ s/\xc3\xa5/E<aring>/g;
70         $line =~ s/\xc3\xa6/E<aelig>/g;
71         $line =~ s/\xc3\xa7/E<ccedil>/g;
72         $line =~ s/\xc3\xa8/E<egrave>/g;
73         $line =~ s/\xc3\xa9/E<eacute>/g;
74         $line =~ s/\xc3\xaa/E<ecirc>/g;
75         $line =~ s/\xc3\xab/E<euml>/g;
76         $line =~ s/\xc3\xac/E<igrave>/g;
77         $line =~ s/\xc3\xad/E<iacute>/g;
78         $line =~ s/\xc3\xae/E<icirc>/g;
79         $line =~ s/\xc3\xaf/E<iuml>/g;
80         $line =~ s/\xc3\xb0/E<eth>/g;
81         $line =~ s/\xc3\xb1/E<ntilde>/g;
82         $line =~ s/\xc3\xb2/E<ograve>/g;
83         $line =~ s/\xc3\xb3/E<oacute>/g;
84         $line =~ s/\xc3\xb4/E<ocirc>/g;
85         $line =~ s/\xc3\xb5/E<otilde>/g;
86         $line =~ s/\xc3\xb6/E<ouml>/g;
87         $line =~ s/\xc3\xb8/E<oslash>/g;
88         $line =~ s/\xc3\xb9/E<ugrave>/g;
89         $line =~ s/\xc3\xba/E<uacute>/g;
90         $line =~ s/\xc3\xbb/E<ucirc>/g;
91         $line =~ s/\xc3\xbc/E<uuml>/g;
92         $line =~ s/\xc3\xbd/E<yacute>/g;
93         $line =~ s/\xc3\xbe/E<thorn>/g;
94         $line =~ s/\xc3\xbf/E<yuml>/g;
95         print $line;
96 }