From 91e41fa737708602a3ccdf87e0a3f2382f1d42da Mon Sep 17 00:00:00 2001 From: Nicholas Clark Date: Tue, 27 Dec 2011 19:44:27 +0100 Subject: [PATCH] installperl now uses get_pod_metadata() to install dual-life pods correctly. This ensures that perlfaq*, perlglossary, perlxs, perlxstut and perldoc's Pod files are installed in the same directory as perl.pod, perlintro.pod etc, as they were in 5.14.0 and earlier releases. This commit is analogous to commit d6a39ee219352c8f, which corrected the install location for man pages. --- installperl | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/installperl b/installperl index 73767bd..10a3781 100755 --- a/installperl +++ b/installperl @@ -29,6 +29,8 @@ use File::Path (); use ExtUtils::Packlist; use Cwd; +require './Porting/pod_lib.pl'; + if ($Is_NetWare) { $Is_W32 = 0; $scr_ext = '.pl'; @@ -126,8 +128,6 @@ close SCRIPTS; if ($scr_ext) { @scripts = map { "$_$scr_ext" } @scripts; } -my @pods = $nopods ? () : (, 'x2p/a2p.pod'); - # Specify here any .pm files that are actually architecture-dependent. # (Those included with XS extensions under ext/ are automatically # added later.) @@ -550,12 +550,11 @@ if ($versiononly) { # Install pod pages. Where? I guess in $installprivlib/pod # ($installprivlib/pods for cygwin). - -my $pod = ($Is_Cygwin || $Is_Darwin || $Is_VMS || $Is_W32) ? 'pods' : 'pod'; -if ( !$versiononly || ($installprivlib =~ m/\Q$vershort/)) { +if (!$nopods && (!$versiononly || ($installprivlib =~ m/\Q$vershort/))) { + my $pod = ($Is_Cygwin || $Is_Darwin || $Is_VMS || $Is_W32) ? 'pods' : 'pod'; mkpath("${installprivlib}/$pod", $opts{verbose}, 0777); - for (@pods) { + for (map {$_->[1]} @{get_pod_metadata()->{master}}) { # $_ is a name like pod/perl.pod (my $base = $_) =~ s#.*/##; copy_if_diff($_, "${installprivlib}/$pod/${base}"); @@ -756,6 +755,9 @@ sub installlib { $name = "$dir/$name" if $dir ne ''; + # ignore pods that are stand alone documentation from dual life modules. + return if /\.pod\z/ && is_duplicate_pod($_); + return if $name eq 'ExtUtils/XSSymSet.pm' and !$Is_VMS; my $installlib = $installprivlib; -- 1.8.3.1