summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJason Woodward2008-12-31 16:04:27 +0000
committerJason Woodward2008-12-31 16:04:27 +0000
commit6ba3480f57ee3f88f59613aa7e722b7130021af5 (patch)
tree801377e0e1496fddd699500d9953e87e9391af29
parenta2e99f48ed63765d510b99c47dc3270cfc130504 (diff)
downloadcpan2tgz-6ba3480f57ee3f88f59613aa7e722b7130021af5.tar.gz
fixed incorrect return value from CPAN::*::make when YAML or YAML::Syck is in use
-rw-r--r--Changelog3
-rwxr-xr-xcpan2tgz11
2 files changed, 12 insertions, 2 deletions
diff --git a/Changelog b/Changelog
index 549ad13..929bc0e 100644
--- a/Changelog
+++ b/Changelog
@@ -1,4 +1,7 @@
+0.6.4 Dec 31, 2008
+ * fixed incorrect return value from CPAN::*::make when YAML or YAML::Syck is in use
+
0.6.3 Dec 19, 2008
* updated dependency parsing for new CPAN.pm in 12.2
diff --git a/cpan2tgz b/cpan2tgz
index 0970de8..ae2b3df 100755
--- a/cpan2tgz
+++ b/cpan2tgz
@@ -28,6 +28,8 @@ use Getopt::Long;
use File::Find ();
our $VERSION = '0.6.3';
+our $HAS_YAML = 1;
+eval "no warnings 'all'; use YAML;"; if ($@) { $HAS_YAML = 0 }
$ENV{PATH} = "/bin:/sbin:/usr/bin:/usr/sbin";
my (
@@ -150,8 +152,13 @@ sub do_package
# do an initial make so that we can get the dep info
eval { $pack->make() or die $!; };
if ( $@ ) {
- print "make ERROR [$module_name]: $!\n";
- exit(1);
+ # make does not return the same when YAML or YAML::Syck is in
+ # use and $! is set to an internal non-fatal value from a YAML
+ # check
+ if (!($! eq 'Inappropriate ioctl for device' && $HAS_YAML)) {
+ print "make ERROR [$module_name]: $!\n";
+ exit(1);
+ }
}
my @deps;