stas 2003/04/29 22:03:36
Modified: perl-framework/Apache-Test Changes README
perl-framework/Apache-Test/lib/Apache TestConfig.pm
TestConfigPerl.pm
Log:
new configuration option: -libmodperl [path/to/]mod_perl.so (so one
can build several DSO objects, rename them, so several builds can
co-exist under the same LIBEXECDIR and test them all. Mainly useful
for testing 3rd party modules, with different mod_perl DSO builds.
Revision Changes Path
1.14 +5 -0 httpd-test/perl-framework/Apache-Test/Changes
Index: Changes
===================================================================
RCS file: /home/cvs/httpd-test/perl-framework/Apache-Test/Changes,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -r1.13 -r1.14
--- Changes 30 Apr 2003 00:47:48 -0000 1.13
+++ Changes 30 Apr 2003 05:03:36 -0000 1.14
@@ -8,6 +8,11 @@
=item 1.01-dev
+new configuration option: -libmodperl [path/to/]mod_perl.so (so one
+can build several DSO objects, rename them, so several builds can
+co-exist under the same LIBEXECDIR and test them all. Mainly useful
+for testing 3rd party modules, with different mod_perl DSO builds. [Stas]
+
set $Apache::Test5005compat::VERSION because of the bogus warnings
generated by EU::MM::parse_version() when it sees
$NOT_THIS_MODULE::VERSION [Randal L. Schwartz <[email protected]>]
1.30 +6 -0 httpd-test/perl-framework/Apache-Test/README
Index: README
===================================================================
RCS file: /home/cvs/httpd-test/perl-framework/Apache-Test/README,v
retrieving revision 1.29
retrieving revision 1.30
diff -u -r1.29 -r1.30
--- README 22 Apr 2003 05:16:40 -0000 1.29
+++ README 30 Apr 2003 05:03:36 -0000 1.30
@@ -94,6 +94,12 @@
configure an httpd other than the default (that apxs figures out)
% t/TEST -httpd ~/ap/httpd-2.0/httpd
+configure a DSO mod_perl object other than the default (that stored in
+Apache::BuildConfig)
+% t/TEST -libmodperl ~/ap/httpd-2.0/modules/mod_perl-5.8.0.so
+or one that can be found relative to LIBEXECDIR
+% t/TEST -libmodperl mod_perl-5.6.1.so
+
switch to another apxs
% t/TEST -apxs ~/ap/httpd-2.0-prefork/bin/apxs
1.160 +1 -0
httpd-test/perl-framework/Apache-Test/lib/Apache/TestConfig.pm
Index: TestConfig.pm
===================================================================
RCS file:
/home/cvs/httpd-test/perl-framework/Apache-Test/lib/Apache/TestConfig.pm,v
retrieving revision 1.159
retrieving revision 1.160
diff -u -r1.159 -r1.160
--- TestConfig.pm 30 Apr 2003 03:29:00 -0000 1.159
+++ TestConfig.pm 30 Apr 2003 05:03:36 -0000 1.160
@@ -58,6 +58,7 @@
proxyssl_url => 'url for testing ProxyPass / https (default is
localhost)',
sslca => 'location of SSL CA (default is $t_conf/ssl/ca)',
sslcaorg => 'SSL CA organization to use for tests (default is asf)',
+ libmodperl => 'path to mod_perl\'s .so (full or relative to
LIBEXECDIR)',
(map { $_ . '_module_name', "$_ module name"} qw(cgi ssl thread access
auth)),
);
1.72 +11 -3
httpd-test/perl-framework/Apache-Test/lib/Apache/TestConfigPerl.pm
Index: TestConfigPerl.pm
===================================================================
RCS file:
/home/cvs/httpd-test/perl-framework/Apache-Test/lib/Apache/TestConfigPerl.pm,v
retrieving revision 1.71
retrieving revision 1.72
diff -u -r1.71 -r1.72
--- TestConfigPerl.pm 23 Apr 2003 02:24:16 -0000 1.71
+++ TestConfigPerl.pm 30 Apr 2003 05:03:36 -0000 1.72
@@ -4,7 +4,7 @@
use strict;
use warnings FATAL => 'all';
-use File::Spec::Functions qw(catfile splitdir abs2rel);
+use File::Spec::Functions qw(catfile splitdir abs2rel file_name_is_absolute);
use File::Find qw(finddepth);
use Apache::TestTrace;
use Apache::TestRequest;
@@ -19,9 +19,17 @@
my $libname = $server->version_of(\%libmodperl);
my $vars = $self->{vars};
- # XXX: $server->{rev} could be set to 2 as a fallback, even when
+ if ($vars->{libmodperl}) {
+ # if set, libmodperl was specified from the command line and
+ # should be used instead of the one that is looked up
+
+ # resolve a non-absolute path
+ $vars->{libmodperl} = $self->find_apache_module($vars->{libmodperl})
+ unless file_name_is_absolute($vars->{libmodperl});
+ }
+ # $server->{rev} could be set to 2 as a fallback, even when
# the wanted version is 1. So check that we use mod_perl 2
- if ($server->{rev} >= 2 && IS_MOD_PERL_2) {
+ elsif ($server->{rev} >= 2 && IS_MOD_PERL_2) {
if (my $build_config = $self->modperl_build_config()) {
$libname = $build_config->{MODPERL_LIB_SHARED};
$vars->{libmodperl} ||= $self->find_apache_module($libname);