Subject: | MakeMaker dependency on Test::More |
ExtUtils::MakeMaker ships with its own Test::More so that it can be
installed or upgraded on systems that don't already have Test::More.
However, two of the tests did not set their @INC properly and so would
fail if Test::More was not already installed.
parse_abstract.t never attempted to adjust @INC.
Liblist_Kid.t tries to set it using getcwd(), but the getcwd is called
before the chdir takes effect and so it gets set incorrectly. The
chdir needs to be in a BEGIN block of its own.
The attached patch fixes both issues.
I can produce this on ami-aecd60c7 (Amazon Linux AMI x86_64 EBS).
Which comes with perl v5.10.1, ExtUtils::MakeMaker 6.55_02
I need to a newer version of MakeMaker, 6.62
perform:
sudo yum -y install cpan gcc make
sudo cpan ExtUtils::MakeMaker < /dev/null
Fails due to (ultimately) lack of Test::More
Subject: | ExtUtils.patch |
diff -r -c ExtUtils-MakeMaker-6.59/t/Liblist_Kid.t ExtUtils-MakeMaker-6.59_fix/t/Liblist_Kid.t
*** ExtUtils-MakeMaker-6.59/t/Liblist_Kid.t Tue Aug 2 15:48:10 2011
--- ExtUtils-MakeMaker-6.59_fix/t/Liblist_Kid.t Wed Jun 27 20:41:44 2012
***************
*** 8,14 ****
BEGIN {
use Cwd;
! chdir 't' if -d 't';
use lib getcwd() . '/lib', getcwd() . '/../lib';
}
--- 8,14 ----
BEGIN {
use Cwd;
! BEGIN {chdir 't' if -d 't';};
use lib getcwd() . '/lib', getcwd() . '/../lib';
}
diff -r -c ExtUtils-MakeMaker-6.59/t/parse_abstract.t ExtUtils-MakeMaker-6.59_fix/t/parse_abstract.t
*** ExtUtils-MakeMaker-6.59/t/parse_abstract.t Mon Feb 7 16:36:59 2011
--- ExtUtils-MakeMaker-6.59_fix/t/parse_abstract.t Wed Jun 27 20:25:52 2012
***************
*** 3,8 ****
--- 3,12 ----
use strict;
use warnings;
+ BEGIN {
+ unshift @INC, 't/lib';
+ }
+
use ExtUtils::MakeMaker;
use Test::More 'no_plan';