CPAN tests fail Makefile.PL using Apache::TestMM - modperl

This is a discussion on CPAN tests fail Makefile.PL using Apache::TestMM - modperl ; How am I supposed to tell CPAN that the distribution requires Apache::TestMM when Makefile.PL uses it before `make` is even executed? So I can't use ExtUtils::MakeMaker's PREREQ_FATAL flag because Makefile.PL does not get that far. http://search.cpan.org/src/MARKLE/Ap...02/Makefile.PL Ugh, do I have ...

+ Reply to Thread
Results 1 to 4 of 4

Thread: CPAN tests fail Makefile.PL using Apache::TestMM

  1. CPAN tests fail Makefile.PL using Apache::TestMM


    How am I supposed to tell CPAN that the distribution
    requires Apache::TestMM when Makefile.PL uses it before
    `make` is even executed? So I can't use
    ExtUtils::MakeMaker's PREREQ_FATAL flag because Makefile.PL
    does not get that far.

    http://search.cpan.org/src/MARKLE/Ap...02/Makefile.PL

    Ugh, do I have to build in a second layer of tests myself?
    I guess a regular test script could generate the
    Apache::Test TEST script and run the sub-suite with
    Test::Harness...

    I've been getting cpan-testers results like this. What
    should I do? Thanks... --m--

    On Thu, 3 Jul 2008, imacat@mail.imacat.idv.tw wrote:

    > This distribution has been tested as part of the cpan-testers
    > effort to test as many new uploads to CPAN as possible. See
    > http://testers.cpan.org/
    > ...
    > This is a computer-generated report for Apache2-Controller-0.0002
    > on perl 5.10.0, created by CPAN-Reporter-1.15.
    >
    > ------------------------------
    > TESTER COMMENTS
    > ------------------------------
    >
    > Additional comments from tester:
    >
    > this report is from an automated smoke testing program
    > and was not reviewed by a human for accuracy
    >
    > ------------------------------
    > PROGRAM OUTPUT
    > ------------------------------
    >
    > Output from '/opt/perl/testers/5.10.0/bin/perl Makefile.PL':
    >
    > Can't locate Apache/TestMM.pm in @INC (@INC contains: /home/imacat/lib/perl5 /opt/perl/testers/5.10.0/lib/5.10.0/x86_64-linux-thread-multi-ld /opt/perl/testers/5.10.0/lib/5.10.0 /opt/perl/testers/5.10.0/lib/site_perl/5.10.0/x86_64-linux-thread-multi-ld /opt/perl/testers/5.10.0/lib/site_perl/5.10.0 .) at Makefile.PL line 7.
    > BEGIN failed--compilation aborted at Makefile.PL line 7.
    >
    > ------------------------------
    > PREREQUISITES
    > ------------------------------
    >
    > Prerequisite modules loaded:
    >
    > No requirements found
    > ...
    >
    > Perl module toolchain versions installed:
    >
    > Module Have
    > ------------------- ---------
    > CPAN 1.9205
    > Cwd 3.2701
    > ExtUtils::CBuilder 0.23
    > ExtUtils::Command 1.14
    > ExtUtils::Install 1.50
    > ExtUtils::MakeMaker 6.44
    > ExtUtils::Manifest 1.54
    > ExtUtils::ParseXS 2.19
    > File::Spec 3.2701
    > Module::Build 0.2808_01
    > Module::Signature 0.55
    > Test::Harness 3.12
    > Test::More 0.80
    > YAML 0.66
    > YAML::Syck n/a
    > version 0.7501
    > ...



  2. Re: CPAN tests fail Makefile.PL using Apache::TestMM

    Mark Hedges wrote:
    > How am I supposed to tell CPAN that the distribution
    > requires Apache::TestMM when Makefile.PL uses it before
    > `make` is even executed? So I can't use
    > ExtUtils::MakeMaker's PREREQ_FATAL flag because Makefile.PL
    > does not get that far.
    >
    > http://search.cpan.org/src/MARKLE/Ap...02/Makefile.PL
    >
    > Ugh, do I have to build in a second layer of tests myself?
    > I guess a regular test script could generate the
    > Apache::Test TEST script and run the sub-suite with
    > Test::Harness...
    >
    > I've been getting cpan-testers results like this. What
    > should I do? Thanks... --m--


    See sub test in:

    http://search.cpan.org/src/PHRED/Apa...10/Makefile.PL

    In short, you override the test target in the Makefile. I can't take
    credit for that code as I stole most of it from Geoff's modules

    I'm trying to abstract a bunch of this dirty work out in
    Apache::Bootstrap, but that is primarily geared at dual life mp1/mp2
    modules, so I don't know how this conditional test code will fit in.

    >
    > On Thu, 3 Jul 2008, imacat@mail.imacat.idv.tw wrote:
    >
    >> This distribution has been tested as part of the cpan-testers
    >> effort to test as many new uploads to CPAN as possible. See
    >> http://testers.cpan.org/
    >> ...
    >> This is a computer-generated report for Apache2-Controller-0.0002
    >> on perl 5.10.0, created by CPAN-Reporter-1.15.
    >>
    >> ------------------------------
    >> TESTER COMMENTS
    >> ------------------------------
    >>
    >> Additional comments from tester:
    >>
    >> this report is from an automated smoke testing program
    >> and was not reviewed by a human for accuracy
    >>
    >> ------------------------------
    >> PROGRAM OUTPUT
    >> ------------------------------
    >>
    >> Output from '/opt/perl/testers/5.10.0/bin/perl Makefile.PL':
    >>
    >> Can't locate Apache/TestMM.pm in @INC (@INC contains: /home/imacat/lib/perl5 /opt/perl/testers/5.10.0/lib/5.10.0/x86_64-linux-thread-multi-ld /opt/perl/testers/5.10.0/lib/5.10.0 /opt/perl/testers/5.10.0/lib/site_perl/5.10.0/x86_64-linux-thread-multi-ld /opt/perl/testers/5.10.0/lib/site_perl/5.10.0 .) at Makefile.PL line 7.
    >> BEGIN failed--compilation aborted at Makefile.PL line 7.
    >>
    >> ------------------------------
    >> PREREQUISITES
    >> ------------------------------
    >>
    >> Prerequisite modules loaded:
    >>
    >> No requirements found
    >> ...
    >>
    >> Perl module toolchain versions installed:
    >>
    >> Module Have
    >> ------------------- ---------
    >> CPAN 1.9205
    >> Cwd 3.2701
    >> ExtUtils::CBuilder 0.23
    >> ExtUtils::Command 1.14
    >> ExtUtils::Install 1.50
    >> ExtUtils::MakeMaker 6.44
    >> ExtUtils::Manifest 1.54
    >> ExtUtils::ParseXS 2.19
    >> File::Spec 3.2701
    >> Module::Build 0.2808_01
    >> Module::Signature 0.55
    >> Test::Harness 3.12
    >> Test::More 0.80
    >> YAML 0.66
    >> YAML::Syck n/a
    >> version 0.7501
    >> ...



    --
    Red Hot Penguin Consulting LLC
    mod_perl/PostgreSQL consulting and implementation
    http://www.redhotpenguin.com/


  3. Re: CPAN tests fail Makefile.PL using Apache::TestMM

    On Fri 04 Jul 2008, Mark Hedges wrote:
    > How am I supposed to tell CPAN that the distribution
    > requires Apache::TestMM when Makefile.PL uses it before
    > `make` is even executed?


    You mustn't die that means return an OK result (exit 0). But you mustn't
    create a Makefile. I do that this way:

    BEGIN {
    eval {
    require ModPerl::MM;
    require Apache::TestMM;
    };
    if( $@ ) {
    exit 0;
    }
    Apache::TestMM->import( qw(test clean) );
    }

    # accept the configs from command line
    Apache::TestMM::filter_args();
    ....

    It is documented, see http://cpantest.grango.org/wiki/CPANAuthorNotes. Look
    for "How can I stop getting FAIL reports for missing libraries or other
    non-Perl dependencies?"

    Torsten

    --
    Need professional mod_perl support?
    Just hire me: torsten.foertsch@gmx.net


  4. Re: CPAN tests fail Makefile.PL using Apache::TestMM



    Mark Hedges wrote:
    > On Thu, 3 Jul 2008, Fred Moyer wrote:
    >>> I've been getting cpan-testers results like this. What
    >>> should I do? Thanks... --m--

    >> See sub test in:
    >>
    >> http://search.cpan.org/src/PHRED/Apa...10/Makefile.PL

    >
    > Wouldn't that Makefile.PL die if mod_perl is not installed,
    > instead of requiring all libs and then running the tests
    > with them when they are followed by the CPAN user?
    >
    > Don't I want it to prompt CPAN to follow dependencies? But
    > if I override &test in this way, how then do I run the tests
    > that need to be run once `make` has begun?
    >
    > Aha, if I use ModPerl::MM then directives will work, nice.
    > Thanks!


    not all things wanting to use Apache::Test have access to (or want)
    mod_perl - Apache-Test is its own distribution on CPAN, so you might not
    have ModPerl::MM

    >
    >> In short, you override the test target in the Makefile.
    >> I can't take credit for that code as I stole most of it
    >> from Geoff's modules

    >
    > Weird with the package namespace and MY:: and whatnot.


    welcome to ExtUtils::MakeMaker

    > But
    > maybe it should just die if it can't require ModPerl::MM. If
    > you haven't installed mod_perl and you can't figure out what
    > to do next, maybe you shouldn't install this module.


    if mod_perl is a requirement, yes.

    >
    >> I'm trying to abstract a bunch of this dirty work out in
    >> Apache::Bootstrap, but that is primarily geared at dual
    >> life mp1/mp2 modules, so I don't know how this conditional
    >> test code will fit in.

    >
    > Sounds like a headache! Yeah I have decided I am too lazy to
    > live in the past while simultaneously trying to keep up.
    > :-)


    this is a Makefile.PL for an Apache-Test-based test suite where mod_perl
    is not required.

    http://search.cpan.org/src/GEOFF/Web...06/Makefile.PL

    HTH

    --Geoff


+ Reply to Thread