Re: ModPerl::MM

[prev] [thread] [next] [Date index for 2004/12/28]

From: Stas Bekman
Subject: Re: ModPerl::MM
Date: 21:53 on 28 Dec 2004
David Wheeler wrote:
> On Dec 28, 2004, at 1:26 PM, Stas Bekman wrote:
> 
>> it can't be any simpler:
> 
> 
> That wasn't the whole script, but I found it on search.cpan.org. Here's 
> how to get it working with Module::Build right now:
> 
> use strict;
> use warnings FATAL => 'all';
> 
> use Apache2;
 >
> use Apache::TestMB;
> 
> # prerequisites
> my %require = (
>     # the keepalive constants and the keepalives() method added in 1.9913
>     "mod_perl"      => "1.9915",
>     "Apache::Test"  => "1.10", # ipv6 fixes
>     'perl'          => 6.006,

perl 6? :)

> );
> 
> my $build_pkg = eval { require Apache::TestMB }
>   ? 'Apache::TestMB'
>   : 'Module::Build';

why Apache::TestMB? It should be ModPerl::MB when it'll appear, right?

why the fallback for Module::Build? Shouldn't it just die then?

what if none exists, should Module::Install be used to require Module::Build?

> my $build = $build_pkg->new(
>     module_name        => 'Apache::Filter::HTTPHeadersFixup',
>     license            => 'perl',
>     requires           => \%require,
>     build_requires     => { Apache::TestMB => 0 },
>     create_makefile_pl => 'passthrough',
>     craete_readme      => 1,
> );
> $build->create_build_script;
> 
> After the release of Module::Build 0.27, you can just do this (no more 
> need to eval TestMB):

when will that be released? I guess I need to require that version then.

> use strict;
> use warnings FATAL => 'all';
> 
> use Apache2;
> use Apache::TestMB;
> 
> # prerequisites
> my %require = (
>     # the keepalive constants and the keepalives() method added in 1.9913
>     "mod_perl"      => "1.9915",
>     "Apache::Test"  => "1.10", # ipv6 fixes
>     'perl'          => 6.006,
> );
> 
> my $build = Module::Build->new(
>     module_name        => 'Apache::Filter::HTTPHeadersFixup',
>     license            => 'perl',
>     requires           => \%require,
>     build_requires     => { Apache::TestMB => 0 },
>     create_makefile_pl => 'passthrough',
>     craete_readme      => 1,
>     build_class        => 'Apache::TestMB',
> );
> $build->create_build_script;

So the only remaining part is to override Module::Build to place modules 
under Apache2/ if mp2 was built this way. Could you post an override that 
unconditionally overrides that and I'll adjust it to figure it out 
dynamically?

Thanks David.


        -- 
        __________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@xxxxxx.xxx http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

-- 
Report problems: http://perl.apache.org/bugs/
Mail list info: http://perl.apache.org/maillist/modperl.html
List etiquette: http://perl.apache.org/maillist/email-etiquette.html

(message missing)

Re: ModPerl::MM
Stas Bekman 20:58 on 28 Dec 2004

Re: ModPerl::MM
David Wheeler 21:14 on 28 Dec 2004

Re: ModPerl::MM
Stas Bekman 21:26 on 28 Dec 2004

Re: ModPerl::MM
David Wheeler 21:42 on 28 Dec 2004

Re: ModPerl::MM
Stas Bekman 21:53 on 28 Dec 2004

Re: ModPerl::MM
Stas Bekman 21:56 on 28 Dec 2004

Re: ModPerl::MM
David Wheeler 22:09 on 28 Dec 2004

Re: ModPerl::MM
Stas Bekman 22:17 on 28 Dec 2004

Re: ModPerl::MM
David Wheeler 22:27 on 28 Dec 2004

Re: ModPerl::MM
Stas Bekman 22:36 on 28 Dec 2004

Re: ModPerl::MM
David Wheeler 22:40 on 28 Dec 2004

Re: ModPerl::MM
Perrin Harkins 00:45 on 29 Dec 2004

Re: ModPerl::MM
Stas Bekman 16:28 on 29 Dec 2004

Generated at 12:16 on 16 Jan 2005 by mariachi v0.52