perl-modperl-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject svn commit: r169644 - in /perl/modperl/trunk: Changes lib/Apache2/Build.pm
Date Wed, 11 May 2005 15:14:53 GMT
Author: stas
Date: Wed May 11 08:14:51 2005
New Revision: 169644

URL: http://svn.apache.org/viewcvs?rev=169644&view=rev
Log:
make sure that the build picks up the include directories based on the
apxs queries and only search the httpd source if $self->{MP_AP_PREFIX}
was set. Earlier it was always picking the headers from the httpd
source if it was available, which was resulting in the wrong headers
if the installed httpd was different than the source that was found

Modified:
    perl/modperl/trunk/Changes
    perl/modperl/trunk/lib/Apache2/Build.pm

Modified: perl/modperl/trunk/Changes
URL: http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=169644&r1=169643&r2=169644&view=diff
==============================================================================
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Wed May 11 08:14:51 2005
@@ -12,6 +12,13 @@
 
 =item 1.999_24-dev
 
+make sure that the build picks up the include directories based on the
+apxs queries and only search the httpd source if $self->{MP_AP_PREFIX}
+was set. Earlier it was always picking the headers from the httpd
+source if it was available, which was resulting in the wrong headers
+if the installed httpd was different than the source that was found
+[Stas]
+
 introduce ModPerl::RegistryPrefork and ModPerl::PerlRunPrefork, which
 behave the same as ModPerl::Registry and ModPerl::PerlRun,
 respectively, but chdir to the script's directory like mod_cgi

Modified: perl/modperl/trunk/lib/Apache2/Build.pm
URL: http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/Apache2/Build.pm?rev=169644&r1=169643&r2=169644&view=diff
==============================================================================
--- perl/modperl/trunk/lib/Apache2/Build.pm (original)
+++ perl/modperl/trunk/lib/Apache2/Build.pm Wed May 11 08:14:51 2005
@@ -940,7 +940,8 @@
 
     return $self->{dir} if $self->{dir};
 
-    if (IS_MOD_PERL_BUILD) {
+    # be careful with the guesswork, or may pick up some wrong headers
+    if (IS_MOD_PERL_BUILD && $self->{MP_AP_PREFIX}) {
         my $build = $self->build_config;
 
         if (my $bdir = $build->{'dir'}) {
@@ -1927,7 +1928,6 @@
         die "Can't find the mod_perl include dir (reason: $reason)";
     }
 
-    my $src = $self->dir;
     my $os = WIN32 ? 'win32' : 'unix';
     push @inc, $self->file_path("src/modules/perl", "xs");
 
@@ -1951,13 +1951,16 @@
         }
     }
 
-    for ("$src/modules/perl", "$src/include",
-         "$src/srclib/apr/include",
-         "$src/srclib/apr-util/include",
-         "$src/os/$os")
-      {
-          push @inc, $_ if -d $_;
-      }
+    if ($self->{MP_AP_PREFIX}) {
+        my $src = $self->dir;
+        for ("$src/modules/perl", "$src/include",
+             "$src/srclib/apr/include",
+             "$src/srclib/apr-util/include",
+             "$src/os/$os")
+            {
+                push @inc, $_ if -d $_;
+            }
+    }
 
     return \@inc;
 }



Mime
View raw message