You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@perl.apache.org by Stas Bekman <st...@stason.org> on 2002/08/14 05:21:33 UTC

building with MP_AP_PREFIX

I was always building with MP_APXS. Now if I try using  MP_AP_PREFIX 
pointing to the httpd-2.0 source tree there are all sort of problems. Am 
I the only one seeing them?

First it cannot find apr.h, which I've fixed with the patch at the end.

Second 'make test' won't start since it cannot find apxs/httpd. What's 
the right thing to do here? We want to move to MP_AP_PREFIX, but it's 
not really working when MP_AP_PREFIX when pointed to the source dir. I 
know this has something to do with win32. does it run 'make test' 
properly on win32?

Finally, the build seems to use / path sep everywhere, shouldn't we use 
catfile()?

Index: lib/Apache/Build.pm
===================================================================
RCS file: /home/cvs/modperl-2.0/lib/Apache/Build.pm,v
retrieving revision 1.103
diff -u -r1.103 Build.pm
--- lib/Apache/Build.pm 14 Aug 2002 02:33:00 -0000      1.103
+++ lib/Apache/Build.pm 14 Aug 2002 03:16:44 -0000
@@ -765,7 +765,12 @@

      my $dir = $self->ap_includedir;

-    my $header = "$dir/apr.h";
+    my $header;
+    for my $d ($dir, "$dir/../srclib/apr/include") {
+        $header = "$d/apr.h";
+        last if -e $header;
+    }
+
      open my $fh, $header or do {
          error "Unable to open $header: $!";
          return undef;



__________________________________________________________________
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: building with MP_AP_PREFIX

Posted by Stas Bekman <st...@stason.org>.
Lyle Brooks wrote:
> I did have a similar problem...
> 
> http://marc.theaimsgroup.com/?l=apache-modperl-dev&m=102452855021159&w=2

Thanks Lyle!

I need to know how it *should* behave in order to fix it. Hopefully Doug 
will provide some insight on this issue.

__________________________________________________________________
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: building with MP_AP_PREFIX

Posted by Lyle Brooks <br...@deseret.com>.
I did have a similar problem...

http://marc.theaimsgroup.com/?l=apache-modperl-dev&m=102452855021159&w=2

Quoting Stas Bekman (stas@stason.org):
> I was always building with MP_APXS. Now if I try using  MP_AP_PREFIX 
> pointing to the httpd-2.0 source tree there are all sort of problems. Am 
> I the only one seeing them?
> 
> First it cannot find apr.h, which I've fixed with the patch at the end.
> 
> Second 'make test' won't start since it cannot find apxs/httpd. What's 
> the right thing to do here? We want to move to MP_AP_PREFIX, but it's 
> not really working when MP_AP_PREFIX when pointed to the source dir. I 
> know this has something to do with win32. does it run 'make test' 
> properly on win32?
> 
> Finally, the build seems to use / path sep everywhere, shouldn't we use 
> catfile()?
> 
> Index: lib/Apache/Build.pm
> ===================================================================
> RCS file: /home/cvs/modperl-2.0/lib/Apache/Build.pm,v
> retrieving revision 1.103
> diff -u -r1.103 Build.pm
> --- lib/Apache/Build.pm 14 Aug 2002 02:33:00 -0000      1.103
> +++ lib/Apache/Build.pm 14 Aug 2002 03:16:44 -0000
> @@ -765,7 +765,12 @@
> 
>       my $dir = $self->ap_includedir;
> 
> -    my $header = "$dir/apr.h";
> +    my $header;
> +    for my $d ($dir, "$dir/../srclib/apr/include") {
> +        $header = "$d/apr.h";
> +        last if -e $header;
> +    }
> +
>       open my $fh, $header or do {
>           error "Unable to open $header: $!";
>           return undef;
> 
> 
> 
> __________________________________________________________________
> 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

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


Re: building with MP_AP_PREFIX

Posted by Stas Bekman <st...@stason.org>.
Doug MacEachern wrote:
> On Wed, 14 Aug 2002, Stas Bekman wrote:
> 
> 
>>I was always building with MP_APXS. Now if I try using  MP_AP_PREFIX 
>>pointing to the httpd-2.0 source tree there are all sort of problems. Am 
>>I the only one seeing them?
> 
> 
> haven't tried pointing it at a source tree in a while.
> what's wrong with pointing it at an install tree?

this is for the case where you want to test before Apache has been 
installed. In any case with my patch and a better explanation regarding 
'make test' it's all dandy now. I just thought that 'make test' could 
find 'httpd' in the source tree as well.

__________________________________________________________________
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: building with MP_AP_PREFIX

Posted by Doug MacEachern <do...@covalent.net>.
On Wed, 14 Aug 2002, Stas Bekman wrote:

> I was always building with MP_APXS. Now if I try using  MP_AP_PREFIX 
> pointing to the httpd-2.0 source tree there are all sort of problems. Am 
> I the only one seeing them?

haven't tried pointing it at a source tree in a while.
what's wrong with pointing it at an install tree?
 
> First it cannot find apr.h, which I've fixed with the patch at the end.

+1
 
> Second 'make test' won't start since it cannot find apxs/httpd. What's 
> the right thing to do here? We want to move to MP_AP_PREFIX, but it's 
> not really working when MP_AP_PREFIX when pointed to the source dir. I 
> know this has something to do with win32. does it run 'make test' 
> properly on win32?

t/TEST -httpd ...
or just point MP_AP_PREFIX at an install tree.
 
> Finally, the build seems to use / path sep everywhere, shouldn't we use 
> catfile()?

doesn't seem to matter much, considering everything works on multiple 
flavors of unix, win32 and osx.


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