Eric:
On Sun Aug 23 13:46:21 2009, enobacon@gmail.com wrote:
Show quoted text> # from Jonathan Yu via RT
> # on Friday 21 August 2009 12:09:
>
> >My distribution (Math::Random::ISAAC::XS) has a test failure which
> >results from a system that has ExtUtils::CBuilder installed, but
> > without any C compiler. Module::Build does not check "have_compiler"
> > anywhere, which results in the build trying to proceed anyway.
>
> How did ExtUtils::CBuilder get installed if t/01-basic.t didn't pass?
It's because in t/01-basic.t:
# test plan
if ( ! $b->have_compiler ) {
plan skip_all => "no compiler available for testing";
}
else {
plan tests => 10;
}
All tests are skipped if there's no compiler, but it's not a *failure*.
That's the point. You should be able to install EUCB even if you don't
have a C compiler. I discussed this with David Golden via IRC.
Show quoted text>
> >Instead, it would be
> >nice of Module::Build checked this during Build.PL -> Build process,
> >and exits there. Then the test failure would be an NA rather than FAIL.
>
> If this is an error in the cpantester's machine, it should be corrected
> on their machine. It is unreasonable to expect M::B to workaround
> pathological cases simply to gloss over a tester's mess.
I'm simply asking M::B to actually test have_compiler before it tries to
build things. That's exactly the point of have_compiler. Keep in mind
that EUCB is just a Pure Perl module, and doesn't require a C compiler
at all.
The report in question happened because someone installed EUCB while not
having a C compiler, which is perfectly legal behaviour. The problem is
how M::B deals with it.
Show quoted text>
> If a real user were to somehow end up in this situation, I think failing
> in a smoking wreck is the right thing to do because they need to
> diagnose and fix their EU::CB installation.
I think failing with a helpful message like "Well, you're trying to
build an XS module but you don't have a C compiler. Please install one
and try again" is better than "blahblah 'cc' not found" which is an
easily understandable message for technical people, but not immediately
obvious for people less familiar with Unix/etc.
Show quoted text>
> --Eric