This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
fix up ABSTRACT_FROM
authorRobin Barker <Robin.Barker@npl.co.uk>
Fri, 25 Sep 2009 12:56:23 +0000 (13:56 +0100)
committerRafael Garcia-Suarez <rgs@consttype.org>
Sun, 27 Sep 2009 15:36:12 +0000 (17:36 +0200)
make_ext.pl

index 04c2add..c6c6378 100644 (file)
@@ -319,6 +319,9 @@ sub build_extension {
            unless ($fromname) {
                die "For $mname tried @locations in in $ext_dir but can't find source";
            }
+            my $pod_name;
+           ($pod_name = $fromname) =~ s/\.pm\z/.pod/;
+           $pod_name = $fromname unless -e $pod_name;
            open my $fh, '>', 'Makefile.PL'
                or die "Can't open Makefile.PL for writing: $!";
            print $fh <<"EOM";
@@ -333,7 +336,7 @@ use ExtUtils::MakeMaker;
 WriteMakefile(
     NAME          => '$mname',
     VERSION_FROM  => '$fromname',
-    ABSTRACT_FROM => '$fromname',
+    ABSTRACT_FROM => '$pod_name',
     realclean     => {FILES => 'Makefile.PL'},
 );