diff options
Diffstat (limited to 'gnu/usr.bin/perl/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Any.pm')
-rw-r--r-- | gnu/usr.bin/perl/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Any.pm | 21 |
1 files changed, 19 insertions, 2 deletions
diff --git a/gnu/usr.bin/perl/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Any.pm b/gnu/usr.bin/perl/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Any.pm index 1a3893c30b6..fc08a612466 100644 --- a/gnu/usr.bin/perl/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Any.pm +++ b/gnu/usr.bin/perl/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Any.pm @@ -1088,8 +1088,9 @@ manifypods : pure_all config $dependencies END my @man_cmds; - foreach my $section (qw(1 3)) { - my $pods = $self->{"MAN${section}PODS"}; + foreach my $num (qw(1 3)) { + my $pods = $self->{"MAN${num}PODS"}; + my $section = $self->{"MAN${num}SECTION"}; my $p2m = sprintf <<'CMD', $section, $] > 5.008 ? " -u" : ""; $(NOECHO) $(POD2MAN) --section=%s --perm_rw=$(PERM_RW)%s CMD @@ -2178,6 +2179,22 @@ sub init_INSTALL_from_PREFIX { if $Verbose >= 2; } + # logic similar to picking man${num}ext in perl's Configure script + foreach my $num (1,3) { + my $mandir + = $self->{ 'INSTALL' . uc $self->{INSTALLDIRS} . "MAN${num}DIR" }; + my $section = $num; + + foreach ($num, "${num}p", "${num}pm", qw< l n o C L >, "L$num") { + if ( $mandir =~ /$_$/ ) { + $section = $_; + last; + } + } + + $self->{"MAN${num}SECTION"} = $section; + } + # Generate these if they weren't figured out. $self->{VENDORARCHEXP} ||= $self->{INSTALLVENDORARCH}; $self->{VENDORLIBEXP} ||= $self->{INSTALLVENDORLIB}; |