perl-embperl mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Florian Schlichting <fschl...@zedat.fu-berlin.de>
Subject test failure(s) with Apache 2.4
Date Thu, 15 Aug 2013 18:39:43 GMT
Hi Gerald,

thank you for your work regarding Perl 5.18, which I hope to be able to
look at soon. In the meantime, I have been struggling to make Embperl
work with Apache 2.4, which is now in Debian testing/unstable for a few
weeks.

Compiling Embperl was relatively straight-forward; all I needed to do
in addition was to source the /etc/apache2/envvars file which sets up a
few paths.

Getting the test suite to pass is more complicated; on Debian, the
provided httpd.conf needs statements to load the desired mpm module, and
there were issues with the LockFile directive, so I added the following
patch:

---8<---

--- a/test/conf/httpd.min.conf.src
+++ b/test/conf/httpd.min.conf.src
@@ -41,6 +41,8 @@

 print OFH "LoadModule embperl_module \"$EPPATH/blib/arch/auto/Embperl/Embperl.so\"\n" if
($MP2) ;

+print OFH "LoadModule mpm_prefork_module /usr/lib/apache2/modules/mod_mpm_prefork.so\n";
# if apache2.4
+

 print OFH <<EOD ;
 ErrorLog tmp/httpd.err.log
@@ -64,7 +66,6 @@

 print OFH <<EOD ;
 TypesConfig conf/null
-LockFile tmp/httpd.lock


 PerlSetEnv EMBPERL_SRC \"$EPPATH\"
--- a/test/conf/httpd.conf.src
+++ b/test/conf/httpd.conf.src
@@ -56,6 +56,10 @@

 print OFH "LoadModule embperl_module \"$EPPATH/blib/arch/auto/Embperl/Embperl.so\"\n" if
($MP2) ;

+print OFH "LoadModule mpm_prefork_module /usr/lib/apache2/modules/mod_mpm_prefork.so\n";
# if apache24
+print OFH "LoadModule authn_core_module /usr/lib/apache2/modules/mod_authn_core.so\n"; #
if apache24
+print OFH "LoadModule authz_core_module /usr/lib/apache2/modules/mod_authz_core.so\n"; #
if apache24
+
 ##print OFH "PassEnv ACTION_PREFIX\n" ;
 print OFH "PerlPassEnv TEST_PRELOAD\n" ;

@@ -118,7 +122,6 @@
 print OFH <<EOD ;

 TypesConfig conf/null
-LockFile tmp/httpd.lock


 # needs mod_log_config

---8<---


But there is one error that I'm left with now: "#32 notfound.htm" works
fine in offline and mod_perl mode, but fails in cgi mode with the
following message:

---8<---
#31 unclosed.htm...           ok
#32 notfound.htm...

Expected 1 more error(s) in logfile

Input:          test/html/notfound.htm
Output:         test/tmp/out.htm
Log:            test/tmp/test.log
Testparameter:
  errors = 1

 ERRORS detected! NOT all tests have been passed successfully
---8<---

out.htm contains a standard Apache 404 page, but test.log as well as
httpd.err.log do not contain anything about the notfound.htm test from
the cgi run (they end with output from unclosed.htm, and contain stuff
from the earlier notfound.htm of the offline and mod_perl runs). When I
add 

    'cgi'        => 0,

to @testdata for notfound.htm in test.pl, the entire test suite passes
successfully.

Any idea what might be the reason, and how to fix this? I'm reluctant to
just disable a failing test...

Florian

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


Mime
View raw message