aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Makefile.am3
-rw-r--r--Makefile.nmake2
-rwxr-xr-xmake-authors-short.pl37
-rwxr-xr-xmake-authors-short2.pl108
4 files changed, 120 insertions, 30 deletions
diff --git a/Makefile.am b/Makefile.am
index e58af10c0b..6b13819e4b 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -300,7 +300,7 @@ svnversion.h: FORCE
#
# Build the short version of the authors file for the about dialog
#
-AUTHORS-SHORT: AUTHORS make-authors-short.pl
+AUTHORS-SHORT: AUTHORS make-authors-short.pl make-authors-short2.pl
$(PERL) $(srcdir)/make-authors-short.pl < AUTHORS > AUTHORS-SHORT
#
@@ -521,6 +521,7 @@ EXTRA_DIST = \
image/icon_layout_6.xpm \
image/wiretap.rc.in \
make-authors-short.pl \
+ make-authors-short2.pl \
make-manuf \
make-tapreg-dotc \
make-version.pl \
diff --git a/Makefile.nmake b/Makefile.nmake
index 516e795b65..27ba0e7a17 100644
--- a/Makefile.nmake
+++ b/Makefile.nmake
@@ -227,7 +227,7 @@ svnversion.h:
#
# Build the short version of the authors file for the about dialog
#
-AUTHORS-SHORT: AUTHORS make-authors-short.pl
+AUTHORS-SHORT: AUTHORS make-authors-short.pl make-authors-short2.pl
$(PERL) make-authors-short.pl < AUTHORS > AUTHORS-SHORT
diff --git a/make-authors-short.pl b/make-authors-short.pl
index 8c8559fafc..caa8b5bc90 100755
--- a/make-authors-short.pl
+++ b/make-authors-short.pl
@@ -2,36 +2,17 @@
# $Id$
-# Remove tasks from individual author entries from AUTHORS file
-# for use in the about dialog.
-
use strict;
-my $subinfo=0;
-my $nextline;
-
-print "=for html <pre>\n\n";
-print "=for man .nf\n\n";
+# Unset environment variables so perl doesn't
+# interpret bytes as UTF-8 characters
-$_ = <>;
-s/\xef\xbb\xbf//; # Skip UTF-8 byte order mark
-print unless /^\n/;
+delete $ENV{LANG};
+delete $ENV{LANGUAGE};
+delete $ENV{LC_ALL};
+delete $ENV{LC_CTYPE};
-while (<>) {
- if (/(.*){/) {
- $subinfo = 1;
- print "$1\n";
- } elsif (/}/) {
- $subinfo = 0;
- if (($nextline = <>) !~ /^[\s]*$/) {
- print $nextline;
- }
- } elsif ($subinfo == 1) {
- next;
- } else {
- print;
- }
-}
+# Call make-authors-short2.pl in same directory, using same interpreter
-print "\n=for html </pre>\n";
-print "\n=for man .fi\n";
+(my $prog2 = $0) =~ s/\.pl$/2.pl/;
+system($^X, "$prog2", @ARGV);
diff --git a/make-authors-short2.pl b/make-authors-short2.pl
new file mode 100755
index 0000000000..eb5e0beb40
--- /dev/null
+++ b/make-authors-short2.pl
@@ -0,0 +1,108 @@
+#!/usr/bin/perl -w
+
+# $Id$
+
+# Remove tasks from individual author entries from AUTHORS file
+# for use in the about dialog.
+
+use strict;
+
+my $subinfo=0;
+my $nextline;
+
+print "=for html <pre>\n\n";
+print "=for man .nf\n\n";
+
+$_ = <>;
+s/\xef\xbb\xbf//; # Skip UTF-8 byte order mark
+printline() unless /^\n/;
+
+while (<>) {
+ if (/(.*){/) {
+ $subinfo = 1;
+ printline("$1\n");
+ } elsif (/}/) {
+ $subinfo = 0;
+ if (($nextline = <>) !~ /^[\s]*$/) {
+ print($nextline);
+ }
+ } elsif ($subinfo == 1) {
+ next;
+ } else {
+ printline();
+ }
+}
+
+print "\n=for html </pre>\n";
+print "\n=for man .fi\n";
+
+sub printline {
+ my $line = shift || $_;
+#
+# Translate UTF-8 characters to the E<> escapes handled by Pod::Man
+# (and only those, since they're a subset of HTML entities)
+#
+ $line =~ s/\xc3\x80/E<Agrave>/g;
+ $line =~ s/\xc3\x81/E<Aacute>/g;
+ $line =~ s/\xc3\x82/E<Acirc>/g;
+ $line =~ s/\xc3\x83/E<Atilde>/g;
+ $line =~ s/\xc3\x84/E<Auml>/g;
+ $line =~ s/\xc3\x85/E<Aring>/g;
+ $line =~ s/\xc3\x86/E<AElig>/g;
+ $line =~ s/\xc3\x87/E<Ccedil>/g;
+ $line =~ s/\xc3\x88/E<Egrave>/g;
+ $line =~ s/\xc3\x89/E<Eacute>/g;
+ $line =~ s/\xc3\x8a/E<Ecirc>/g;
+ $line =~ s/\xc3\x8b/E<Euml>/g;
+ $line =~ s/\xc3\x8c/E<Igrave>/g;
+ $line =~ s/\xc3\x8d/E<Iacute>/g;
+ $line =~ s/\xc3\x8e/E<Icirc>/g;
+ $line =~ s/\xc3\x8f/E<Iuml>/g;
+ $line =~ s/\xc3\x90/E<ETH>/g;
+ $line =~ s/\xc3\x91/E<Ntilde>/g;
+ $line =~ s/\xc3\x92/E<Ograve>/g;
+ $line =~ s/\xc3\x93/E<Oacute>/g;
+ $line =~ s/\xc3\x94/E<Ocirc>/g;
+ $line =~ s/\xc3\x95/E<Otilde>/g;
+ $line =~ s/\xc3\x96/E<Ouml>/g;
+ $line =~ s/\xc3\x98/E<Oslash>/g;
+ $line =~ s/\xc3\x99/E<Ugrave>/g;
+ $line =~ s/\xc3\x9a/E<Uacute>/g;
+ $line =~ s/\xc3\x9b/E<Ucirc>/g;
+ $line =~ s/\xc3\x9c/E<Uuml>/g;
+ $line =~ s/\xc3\x9d/E<Yacute>/g;
+ $line =~ s/\xc3\x9e/E<THORN>/g;
+ $line =~ s/\xc3\x9f/E<szlig>/g;
+ $line =~ s/\xc3\xa0/E<agrave>/g;
+ $line =~ s/\xc3\xa1/E<aacute>/g;
+ $line =~ s/\xc3\xa2/E<acirc>/g;
+ $line =~ s/\xc3\xa3/E<atilde>/g;
+ $line =~ s/\xc3\xa4/E<auml>/g;
+ $line =~ s/\xc3\xa5/E<aring>/g;
+ $line =~ s/\xc3\xa6/E<aelig>/g;
+ $line =~ s/\xc3\xa7/E<ccedil>/g;
+ $line =~ s/\xc3\xa8/E<egrave>/g;
+ $line =~ s/\xc3\xa9/E<eacute>/g;
+ $line =~ s/\xc3\xaa/E<ecirc>/g;
+ $line =~ s/\xc3\xab/E<euml>/g;
+ $line =~ s/\xc3\xac/E<igrave>/g;
+ $line =~ s/\xc3\xad/E<iacute>/g;
+ $line =~ s/\xc3\xae/E<icirc>/g;
+ $line =~ s/\xc3\xaf/E<iuml>/g;
+ $line =~ s/\xc3\xb0/E<eth>/g;
+ $line =~ s/\xc3\xb1/E<ntilde>/g;
+ $line =~ s/\xc3\xb2/E<ograve>/g;
+ $line =~ s/\xc3\xb3/E<oacute>/g;
+ $line =~ s/\xc3\xb4/E<ocirc>/g;
+ $line =~ s/\xc3\xb5/E<otilde>/g;
+ $line =~ s/\xc3\xb6/E<ouml>/g;
+ $line =~ s/\xc3\xb8/E<oslash>/g;
+ $line =~ s/\xc3\xb9/E<ugrave>/g;
+ $line =~ s/\xc3\xba/E<uacute>/g;
+ $line =~ s/\xc3\xbb/E<ucirc>/g;
+ $line =~ s/\xc3\xbc/E<uuml>/g;
+ $line =~ s/\xc3\xbd/E<yacute>/g;
+ $line =~ s/\xc3\xbe/E<thorn>/g;
+ $line =~ s/\xc3\xbf/E<yuml>/g;
+ print $line;
+}