From 23b61cc4ac925c0139c3456c4672dc2d306af7fe Mon Sep 17 00:00:00 2001 From: Justin Davis Date: Fri, 6 Jan 2012 21:35:46 -0500 Subject: Add name overrides for packages that bend the rules. --- lib/metas/perl | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'lib/metas') diff --git a/lib/metas/perl b/lib/metas/perl index b53cd61..adb3b08 100755 --- a/lib/metas/perl +++ b/lib/metas/perl @@ -8,6 +8,7 @@ use IO::Handle; # for autoflush use Cwd; my $PROG = 'perl'; +my %BADNAMES = ('perl-libwww' => 'libwww-perl'); sub err { @@ -64,10 +65,13 @@ sub fetchdist sub main { - my $pkg = shift or die "Usage: $PROG [package name]\n"; - my $dist = $pkg; + my $dist = shift or die "Usage: $PROG [package name]\n"; - $dist = "app-$dist" if($dist =~ s/^perl-// == 0); + if($BADNAMES{$dist}){ + $dist = $BADNAMES{$dist}; + }elsif($dist =~ s/^perl-// == 0){ + $dist = "app-$dist"; + } STDERR->autoflush(1); my ($realname, $cpath) = matchdist($dist); -- cgit v1.2.3-24-g4f1b