diff options
author | Craig A. Berry <craigberry@mac.com> | 2016-01-28 13:44:07 -0600 |
---|---|---|
committer | Craig A. Berry <craigberry@mac.com> | 2016-01-30 12:42:17 -0600 |
commit | d42e1eb74e834d1cf3ac4b5c9bd3527c3d5da67b (patch) | |
tree | f9d4e57bd2ae05be3df685a76b0d0057455321a5 /make_ext.pl | |
parent | d9a72bf2e96ce4f217a832a9106c027edfdc45f3 (diff) | |
download | perl-d42e1eb74e834d1cf3ac4b5c9bd3527c3d5da67b.tar.gz |
Integrate podlators 4.05.
Diffstat (limited to 'make_ext.pl')
-rw-r--r-- | make_ext.pl | 45 |
1 files changed, 18 insertions, 27 deletions
diff --git a/make_ext.pl b/make_ext.pl index 0745049556..659445808a 100644 --- a/make_ext.pl +++ b/make_ext.pl @@ -352,35 +352,26 @@ sub build_extension { print "\nCreating Makefile.PL in $ext_dir for $mname\n" if $verbose; my ($fromname, $key, $value); - if ($mname eq 'podlators') { - # We need to special case this somewhere, and this is fewer - # lines of code than a core-only Makefile.PL, and no more - # complex - $fromname = 'VERSION'; - $key = 'DISTNAME'; - $value = 'podlators'; - $mname = 'Pod'; - } else { - $key = 'ABSTRACT_FROM'; - # We need to cope well with various possible layouts - my @dirs = split /::/, $mname; - my $leaf = pop @dirs; - my $leafname = "$leaf.pm"; - my $pathname = join '/', @dirs, $leafname; - my @locations = ($leafname, $pathname, "lib/$pathname"); - foreach (@locations) { - if (-f $_) { - $fromname = $_; - last; - } - } - unless ($fromname) { - die "For $mname tried @locations in $ext_dir but can't find source"; + $key = 'ABSTRACT_FROM'; + # We need to cope well with various possible layouts + my @dirs = split /::/, $mname; + my $leaf = pop @dirs; + my $leafname = "$leaf.pm"; + my $pathname = join '/', @dirs, $leafname; + my @locations = ($leafname, $pathname, "lib/$pathname"); + foreach (@locations) { + if (-f $_) { + $fromname = $_; + last; } - ($value = $fromname) =~ s/\.pm\z/.pod/; - $value = $fromname unless -e $value; - } + } + + unless ($fromname) { + die "For $mname tried @locations in $ext_dir but can't find source"; + } + ($value = $fromname) =~ s/\.pm\z/.pod/; + $value = $fromname unless -e $value; if ($mname eq 'Pod::Checker') { # the abstract in the .pm file is unparseable by MM, |