You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@perl.apache.org by Randy Kobes <ra...@theoryx5.uwinnipeg.ca> on 2004/08/01 08:45:06 UTC

[mp2] building aprext

I've attached a patch (as it includes tabs) for building the
static aprext lib for Win32 (and perhaps others) when need
be in providing symbols to APR/APR::* so as to be usable
outside of mod_perl.so. What this does is hopfully make it
easier to configure other platforms (than Win32) to build it
this way - a constant BUILD_APREXT is defined in
Apache::Build, so to add another platform to this way of
building, one just has to modify this constant, as well as
provide a mp_apr_lib_$^O sub in Apache::Build to instruct
how to link to the aprext lib.

I've changed the actual name of the lib used to libaprext,
to make it easier on *nix to use "-laprext" linking.

-- 
best regards,
randy

Re: [mp2] building aprext

Posted by Randy Kobes <ra...@theoryx5.uwinnipeg.ca>.
On Sun, 1 Aug 2004, Stas Bekman wrote:

> Randy Kobes wrote:
> > On Sun, 1 Aug 2004, Stas Bekman wrote:
> >
> >
> >>Randy Kobes wrote:
> >>
> >>>I've attached a patch (as it includes tabs) for building the
> >>>static aprext lib for Win32 (and perhaps others) when need
> >>>be in providing symbols to APR/APR::* so as to be usable
> >>>outside of mod_perl.so.
> >
> > [ ... ]
> >
> >>Nice work, Randy
> >>
> >>The only comment I have is that there is a lot of code
> >>duplication going on in Makefile.PL. It think it should be
> >>abstracted into a sub.
> >
> > Thanks, Stas - that's a good idea. In the attached, I put
> > the code to get the directory and name of the built aprext
> > lib into an Apache::Build sub.
>
> Excellent.
>
> > Index: xs/APR/APR/Makefile.PL
> > ===================================================================
> > RCS file: /home/cvs/modperl-2.0/xs/APR/APR/Makefile.PL,v
> > retrieving revision 1.25
> > diff -u -r1.25 Makefile.PL
> > --- xs/APR/APR/Makefile.PL	4 Jul 2004 18:44:49 -0000	1.25
> > +++ xs/APR/APR/Makefile.PL	1 Aug 2004 18:00:02 -0000
> > @@ -9,6 +9,7 @@
> >  use File::Spec::Functions;
> >
> >  use constant WIN32   => Apache::Build::WIN32;
> > +use constant BUILD_APREXT   => Apache::Build::BUILD_APREXT;
> >  use constant SOLARIS => $^O eq 'solaris';
>
> I'd swap the constants here, keeping the OS aliases together.
>
> Now, the AIX stuff... we don't know whether it works at all, so may be
> do that in two stages - commit the generalization of win32, then get the
> aix changes as a patch and get someone to test it before committing it.
> Otherwise we may break, otherwise working things.

Thanks, Stas - I'll swap the order of those constants and
also take out the AIX stuff and commit.

-- 
best regards,
randy

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: [mp2] building aprext

Posted by Stas Bekman <st...@stason.org>.
Randy Kobes wrote:
> On Sun, 1 Aug 2004, Stas Bekman wrote:
> 
> 
>>Randy Kobes wrote:
>>
>>>I've attached a patch (as it includes tabs) for building the
>>>static aprext lib for Win32 (and perhaps others) when need
>>>be in providing symbols to APR/APR::* so as to be usable
>>>outside of mod_perl.so.
> 
> [ ... ]
> 
>>Nice work, Randy
>>
>>The only comment I have is that there is a lot of code
>>duplication going on in Makefile.PL. It think it should be
>>abstracted into a sub.
> 
> 
> Thanks, Stas - that's a good idea. In the attached, I put
> the code to get the directory and name of the built aprext
> lib into an Apache::Build sub.

Excellent.

> Index: xs/APR/APR/Makefile.PL
> ===================================================================
> RCS file: /home/cvs/modperl-2.0/xs/APR/APR/Makefile.PL,v
> retrieving revision 1.25
> diff -u -r1.25 Makefile.PL
> --- xs/APR/APR/Makefile.PL	4 Jul 2004 18:44:49 -0000	1.25
> +++ xs/APR/APR/Makefile.PL	1 Aug 2004 18:00:02 -0000
> @@ -9,6 +9,7 @@
>  use File::Spec::Functions;
>  
>  use constant WIN32   => Apache::Build::WIN32;
> +use constant BUILD_APREXT   => Apache::Build::BUILD_APREXT;
>  use constant SOLARIS => $^O eq 'solaris';

I'd swap the constants here, keeping the OS aliases together.

Now, the AIX stuff... we don't know whether it works at all, so may be 
do that in two stages - commit the generalization of win32, then get the 
aix changes as a patch and get someone to test it before committing it. 
Otherwise we may break, otherwise working things.

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

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: [mp2] building aprext

Posted by Randy Kobes <ra...@theoryx5.uwinnipeg.ca>.
On Sun, 1 Aug 2004, Stas Bekman wrote:

> Randy Kobes wrote:
> > I've attached a patch (as it includes tabs) for building the
> > static aprext lib for Win32 (and perhaps others) when need
> > be in providing symbols to APR/APR::* so as to be usable
> > outside of mod_perl.so.
[ ... ]
>
> Nice work, Randy
>
> The only comment I have is that there is a lot of code
> duplication going on in Makefile.PL. It think it should be
> abstracted into a sub.

Thanks, Stas - that's a good idea. In the attached, I put
the code to get the directory and name of the built aprext
lib into an Apache::Build sub.

-- 
best regards,
randy

Re: [mp2] building aprext

Posted by Stas Bekman <st...@stason.org>.
Randy Kobes wrote:
> I've attached a patch (as it includes tabs) for building the
> static aprext lib for Win32 (and perhaps others) when need
> be in providing symbols to APR/APR::* so as to be usable
> outside of mod_perl.so. What this does is hopfully make it
> easier to configure other platforms (than Win32) to build it
> this way - a constant BUILD_APREXT is defined in
> Apache::Build, so to add another platform to this way of
> building, one just has to modify this constant, as well as
> provide a mp_apr_lib_$^O sub in Apache::Build to instruct
> how to link to the aprext lib.
> 
> I've changed the actual name of the lib used to libaprext,
> to make it easier on *nix to use "-laprext" linking.

Nice work, Randy

The only comment I have is that there is a lot of code duplication going 
on in Makefile.PL. It think it should be abstracted into a sub.

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

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org