summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJason Woodward2008-12-19 22:58:12 +0000
committerJason Woodward2008-12-19 22:58:12 +0000
commit45012a5c627a603341bac66d4ae81c79c3bf49a9 (patch)
tree74597d610398513ab6ba499b3da9c659679bebd5
parent3ae50d63e7a4a9c3b29d3a2494ff01204794d3a0 (diff)
downloadcpan2tgz-45012a5c627a603341bac66d4ae81c79c3bf49a9.tar.gz
updated dependency parsing for new CPAN.pm in 12.2
-rw-r--r--Changelog3
-rwxr-xr-xcpan2tgz7
2 files changed, 8 insertions, 2 deletions
diff --git a/Changelog b/Changelog
index c7c1d5d..549ad13 100644
--- a/Changelog
+++ b/Changelog
@@ -1,4 +1,7 @@
+0.6.3 Dec 19, 2008
+ * updated dependency parsing for new CPAN.pm in 12.2
+
0.6.2 Feb 27, 2007
* Exit on installpkg error
* Fix for using --ingnoreinstalled with packages w/o dependencies (thanks Cedric Ferry)
diff --git a/cpan2tgz b/cpan2tgz
index 2b65945..0970de8 100755
--- a/cpan2tgz
+++ b/cpan2tgz
@@ -27,7 +27,7 @@ use CPAN;
use Getopt::Long;
use File::Find ();
-our $VERSION = '0.6.2';
+our $VERSION = '0.6.3';
$ENV{PATH} = "/bin:/sbin:/usr/bin:/usr/sbin";
my (
@@ -156,11 +156,13 @@ sub do_package
my @deps;
if ($ignore_installed_deps && $pack->prereq_pm()) {
+ my $deps = $pack->prereq_pm();
# only get the deps that are not installed
@deps = grep { defined && m/\w+/; }
map { defined $PACKAGE_CACHE_LIST{$_} ? undef : $_ }
- keys %{$pack->prereq_pm()};
+ map { m/requires$/ ? keys %{$deps->{$_}} : $_ }
+ keys %{$deps};
} elsif (my $deps = $pack->prereq_pm()) {
@@ -168,6 +170,7 @@ sub do_package
@deps = grep { $_ && m/\w+/; }
map { defined $PACKAGE_CACHE_LIST{$_} ? undef : $_ }
map { eval "no warnings 'all'; use $_;"; if ($@) { $_ } }
+ map { m/requires$/ ? keys %{$deps->{$_}} : $_ }
keys %{$deps};
}