diff options
author | Nicholas Clark <nick@ccl4.org> | 2011-12-22 17:02:01 +0100 |
---|---|---|
committer | Nicholas Clark <nick@ccl4.org> | 2011-12-24 10:27:36 +0100 |
commit | 1cb2462dfbfd850261a04986dde33d544c98a935 (patch) | |
tree | 9d4a2445a0190272947a09dd62bfafff8d04927b | |
parent | 65e5b0167e9699a603db53d07657ab54bfacfa34 (diff) | |
download | perl-1cb2462dfbfd850261a04986dde33d544c98a935.tar.gz |
Avoid installman warning about "no documentation in pod/perldoc.pod"
Since commit a2afbef4476f724a in July 2011 moved perldoc.pod from pod/ to
dist/Pod-Perldoc/lib/ installman will have been warning
"no documentation in pod/perldoc.pod", having already installed the perldoc
man page earlier in the process.
However, the reference in utils.lst has actually been arguably erroneous
since it was added in commit cd0cddc9814dd65e (July 2003) to stop installman
installing an empty perldoc.1 manpage. (Which it had been doing since commit
1a67fee7d910c677 (December 2002), as a side effect of overwriting the
correct file (sourced from pod/perldoc.pod) with an incorrect file (sourced
from scanning utils/perldoc for Pod). The fix "worked" by causing perldoc.1
to be written correctly twice, both times sourced from pod/perldoc.pod :-)
The best fix seems to be to remember the names of the manpages we install
in man1, and automatically skip processing for any utility whose manpage
has already been installed.
-rwxr-xr-x | installman | 10 | ||||
-rw-r--r-- | utils.lst | 2 |
2 files changed, 5 insertions, 7 deletions
diff --git a/installman b/installman index ced3028dc0..4197a8f325 100755 --- a/installman +++ b/installman @@ -14,7 +14,7 @@ use Pod::Man; use vars qw(%opts $packlist); require './Porting/pod_lib.pl'; -my $state = get_pod_metadata(); +my %man1 = (map {($_->[0], $_->[1])} @{get_pod_metadata()->{master}}); $ENV{SHELL} = 'sh' if $^O eq 'os2'; @@ -64,11 +64,7 @@ $opts{verbose} ||= $opts{V} || $opts{notify}; $packlist = ExtUtils::Packlist->new("$opts{destdir}$Config{installarchlib}/.packlist"); # Install the main pod pages. -pod2man({ - map { - ($_->[0], $_->[1]) - } @{$state->{master}} - }, $opts{man1dir}, $opts{man1ext}, 'pod'); +pod2man(\%man1, $opts{man1dir}, $opts{man1ext}, 'pod'); # Install the pods for library modules. { @@ -85,6 +81,8 @@ while (<UTILS>) { chomp; $_ = $1 if /#.*pod\s*=\s*(\S+)/; my ($path, $leaf) = m|^(\S*/(\S+))|; + # Have we already installed the manpage for this? (ie perldoc) + next if $man1{$leaf}; $leaf =~ s/\.pod\z//; pod2man({$leaf, $path}, $opts{man1dir}, $opts{man1ext}); if ($has_man1dir) { @@ -15,7 +15,7 @@ utils/instmodsh utils/json_pp utils/libnetcfg utils/perlbug # link = utils/perlthanks -utils/perldoc # pod = pod/perldoc.pod +utils/perldoc utils/perlivp utils/piconv utils/pl2pm |