porting modperl to httpd 2.4

git-svn-id: https://svn.apache.org/repos/asf/perl/modperl/branches/httpd24@1151159 13f79535-47bb-0310-9956-ffa450edef68
Initialized merge tracking via "svnmerge" with revisions "1-1151156" from 
https://svn.eu.apache.org/repos/asf/perl/modperl/trunk


git-svn-id: https://svn.apache.org/repos/asf/perl/modperl/branches/httpd24@1151172 13f79535-47bb-0310-9956-ffa450edef68
Allow for multiline Perl statements in the "#_if_" minilanguage in
map files like xs/maps/apache2_functions.map

Before this change one would have to write

#_if_ do { long perl expression; another perl expression }

After it can span over multiple lines:

#_if_ do {                     \
  long perl expression;        \
  another perl expression;     \
}


git-svn-id: https://svn.apache.org/repos/asf/perl/modperl/branches/httpd24@1151816 13f79535-47bb-0310-9956-ffa450edef68
As of httpd 2.4 the MPM becomes a loadable module. Thus, modperl should
in principle require a threaded perl always. But if the admin knows that
only prefork will be used he can call "perl Makefile.PL NONTHREADED_OK=1"
to have the build process accept a non-threaded perl.


git-svn-id: https://svn.apache.org/repos/asf/perl/modperl/branches/httpd24@1151822 13f79535-47bb-0310-9956-ffa450edef68
make modperl compilable with httpd 2.3.14.


git-svn-id: https://svn.apache.org/repos/asf/perl/modperl/branches/httpd24@1151827 13f79535-47bb-0310-9956-ffa450edef68
ap_default_type() is gone in httpd 2.3.2

git-svn-id: https://svn.apache.org/repos/asf/perl/modperl/branches/httpd24@1152576 13f79535-47bb-0310-9956-ffa450edef68
Merged revisions 1213838,1213841,1213902,1221285,1221359,1222775,1241435,1241873,1243923,1244184,1245946,1290839,1291667,1299429,1299669,1301966,1302389,1302431,1302463,1311623,1311963,1328477,1328479,1330023,1330345,1330548,1344224,1346710,1346712,1346720,1362399,1362409,1362412,1410264,1410291,1410293,1410295,1410298-1410299,1410314,1410316,1410327,1410329,1410343,1410345,1410400,1410407,1410425,1410427,1419582 via svnmerge from 
https://svn.apache.org/repos/asf/perl/modperl/trunk

........
  r1213838 | gozer | 2011-12-13 19:33:18 +0100 (Tue, 13 Dec 2011) | 3 lines
  
  Avoid -Wall warning when mg_flags isn't used.
........
  r1213841 | gozer | 2011-12-13 19:34:16 +0100 (Tue, 13 Dec 2011) | 5 lines
  
  When generating XS code, include var = var; declarations on the arguments,
  since we don't know if they will be used, and we want to keep -Wall builds
  succeeding.
........
  r1213902 | gozer | 2011-12-13 21:04:15 +0100 (Tue, 13 Dec 2011) | 3 lines
  
  Silence a compiler warning when MP_TRACE is not enabled
........
  r1221285 | gozer | 2011-12-20 15:40:21 +0100 (Tue, 20 Dec 2011) | 6 lines
  
  Adjust for latest ExtUtils::MakeMaker internal change. We must call init_tools when
  it is available.
  
  Reference: https://github.com/Perl-Toolchain-Gang/ExtUtils-MakeMaker/commit/f4904b4ce499b7f0c420efae69f44e19fe7dd12f
........
  r1221359 | gozer | 2011-12-20 18:22:31 +0100 (Tue, 20 Dec 2011) | 7 lines
  
  Apache 2.4 and onwards doesn't require linking the MPM module directly in
  the httpd binary anymore. APXS lost the MPM_NAME query, so we can't assume
  a given MPM anymore. Introduce a fake MPM 'dynamic' to represent this. 
  
  Borrowed from the 2.4 branch
........
  r1222775 | gozer | 2011-12-23 19:20:27 +0100 (Fri, 23 Dec 2011) | 3 lines
  
  Discover apr-2-config from Apache 2.4 onwards.
........
  r1241435 | torsten | 2012-02-07 13:00:45 +0100 (Tue, 07 Feb 2012) | 3 lines
  
  Fix a small bug in a debugging message in modperl_module.c. It tried to
  print a modperl_mgv_t* as %s.
........
  r1241873 | torsten | 2012-02-08 12:46:27 +0100 (Wed, 08 Feb 2012) | 1 line
  
  reverting change 1145161
........
  r1243923 | stevehay | 2012-02-14 15:04:05 +0100 (Tue, 14 Feb 2012) | 2 lines
  
  Correct the initialization of the build config in ModPerl::MM, simply borrowing the style of ModPerl::BuildMM to do so.
........
  r1244184 | torsten | 2012-02-14 20:29:11 +0100 (Tue, 14 Feb 2012) | 12 lines
  
  Fix 2 SV REFCNT bugs:
  
  - modperl_perl_core_global_init(), the aliasing GV references the aliased
    CV. Thus, it should increment the REFCNT.
  - new_constsub() in modperl_const.c, same story.
  
  The bug has been there for years. Only starting with perl 5.14 it became
  visible by messages like this in the error_log:
  
    Attempt to free unreferenced scalar: SV 0x7fc218, 
        Perl interpreter: 0x7cfdb0 during global destruction.
........
  r1245946 | torsten | 2012-02-18 16:38:49 +0100 (Sat, 18 Feb 2012) | 1 line
  
  avoid hard-wired $(MAKE) options
........
  r1290839 | torsten | 2012-02-18 19:31:38 +0100 (Sat, 18 Feb 2012) | 1 line
  
  pass MP_APXS and MP_AP_PREFIX to submodule Makefile.PLs as environment variables
........
  r1291667 | stevehay | 2012-02-21 09:59:19 +0100 (Tue, 21 Feb 2012) | 3 lines
  
  Ensure that MP_APXS is set when building on Win32 with MP_AP_PREFIX,
  otherwise the bundled Reload and SizeLimit builds will fail to find a
  properly configured Test environment.
........
  r1299429 | torsten | 2012-03-11 20:09:47 +0100 (Sun, 11 Mar 2012) | 4 lines
  
  Fix a race condition in our tipool management.
  See http://www.gossamer-threads.com/lists/modperl/dev/104026
  Patch submitted by: SalusaSecondus <salusa@nationstates.net>
........
  r1299669 | torsten | 2012-03-12 14:27:30 +0100 (Mon, 12 Mar 2012) | 1 line
  
  Do not stringify $@ upon exception propagation.
........
  r1301966 | torsten | 2012-03-17 18:25:01 +0100 (Sat, 17 Mar 2012) | 1 line
  
  fix a few false positive warnings when compiled with -Werror=format-security (reported by Niko Tyni)
........
  r1302389 | torsten | 2012-03-19 13:03:52 +0100 (Mon, 19 Mar 2012) | 7 lines
  
  Pool cleanup functions must not longjmp. Catch these exceptions and turn
  them into warnings.
  
  Affected methods:
    APR::Pool->cleanup_register
    Apache2::ServerUtil->server_shutdown_cleanup_register
........
  r1302431 | torsten | 2012-03-19 14:47:18 +0100 (Mon, 19 Mar 2012) | 2 lines
  
  Adopt modperl_pcw.c changes from httpd24 branch.
........
  r1302463 | torsten | 2012-03-19 15:13:26 +0100 (Mon, 19 Mar 2012) | 1 line
  
  add another pool cleanup exception test
........
  r1311623 | stevehay | 2012-04-10 10:03:21 +0200 (Tue, 10 Apr 2012) | 1 line
  
  Move code after declarations to keep MSVC++ compiler happy.
........
  r1311963 | phred | 2012-04-10 22:05:01 +0200 (Tue, 10 Apr 2012) | 1 line
  
  attribute rc4 changes
........
  r1328477 | aprime | 2012-04-20 20:47:05 +0200 (Fri, 20 Apr 2012) | 3 lines
  
  add ifdef's for MUTABLE_CV usage to preserve perl 5.8.5 compatibility
........
  r1328479 | aprime | 2012-04-20 21:07:44 +0200 (Fri, 20 Apr 2012) | 2 lines
  
  Add changes entry
........
  r1330023 | phred | 2012-04-24 23:31:35 +0200 (Tue, 24 Apr 2012) | 1 line
  
  Releasing 2.0.6
........
  r1330345 | phred | 2012-04-25 17:30:13 +0200 (Wed, 25 Apr 2012) | 1 line
  
  Releasing 2.0.6
........
  r1330548 | phred | 2012-04-25 22:42:13 +0200 (Wed, 25 Apr 2012) | 1 line
  
  start 2.0.7-dev cycle
........
  r1344224 | stevehay | 2012-05-30 14:24:43 +0200 (Wed, 30 May 2012) | 2 lines
  
  Apply patch from rt.cpan.org #77129 to fix breakage caused by removal of PL_uid et al from perl 5.16.0.
........
  r1346710 | phred | 2012-06-06 04:16:19 +0200 (Wed, 06 Jun 2012) | 2 lines
  
  Yep, I think we're stable by now ;)
........
  r1346712 | phred | 2012-06-06 04:19:11 +0200 (Wed, 06 Jun 2012) | 1 line
  
  Releasing 2.0.7
........
  r1346720 | phred | 2012-06-06 04:44:23 +0200 (Wed, 06 Jun 2012) | 1 line
  
  start 2.0.8-dev cycle
........
  r1362399 | stevehay | 2012-07-17 10:14:58 +0200 (Tue, 17 Jul 2012) | 4 lines
  
  Remove all uses of deprecated symbols no longer used by core perl and now only defined when PERL_CORE is not defined for backwards compatibility with CPAN extensions still making use of them:
  MEMBER_TO_FPTR, New, NEWSV, Newz, Null, Nullav, Nullch, Nullcv, Nullfp, Nullgv, Nullhv, Nullsv, PL_dirty, PL_na.
  
  We actually (and arguably, wrongly) define PERL_CORE for an optimization in certain cases (but not when large files support is enabled, hence this doesn't happen often) and therefore don't get the definitions of these legacy symbols in that case. This commit fixes that, so that mod_perl can once again be built without large files support, but ideally our usage of PERL_CORE should be removed anyway.
........
  r1362409 | stevehay | 2012-07-17 10:43:28 +0200 (Tue, 17 Jul 2012) | 1 line
  
  Fix commit 1362399: PL_phase/PERL_PHASE_DESTRUCT is only available in newer perls, so restore use of PL_dirty for older perls (where it was always available, regardless of whether PERL_CORE was defined).
........
  r1362412 | stevehay | 2012-07-17 10:57:34 +0200 (Tue, 17 Jul 2012) | 1 line
  
  Update Changes file for commits 1362399 and 1362409.
........
  r1410264 | jorton | 2012-11-16 10:28:51 +0100 (Fri, 16 Nov 2012) | 4 lines
  
  * src/modules/perl/modperl_interp.c (modperl_interp_select): Fix for httpd 2.4.
  
  Submitted by: Jan Kaluza <jkaluza redhat.com>, jorton
........
  r1410291 | jorton | 2012-11-16 11:44:55 +0100 (Fri, 16 Nov 2012) | 6 lines
  
  * src/modules/perl/modperl_apache_compat.h: Fix definition of
    MP_HTTPD_OVERRIDE_OPTS_DEFAULT for 2.4.
  
  Obtained from: branches/httpd24
  Submitted by: torsten
........
  r1410293 | jorton | 2012-11-16 11:46:24 +0100 (Fri, 16 Nov 2012) | 2 lines
  
  * src/modules/perl/modperl_apache_compat.h: Fix version test.
........
  r1410295 | jorton | 2012-11-16 11:49:00 +0100 (Fri, 16 Nov 2012) | 4 lines
  
  * src/modules/perl/modperl_apache_includes.h: Use 2.4 logging API.
  
  Submitted by: Stefan Fritsch <sf sfritsch.de>, jorton
........
  r1410298 | jorton | 2012-11-16 11:52:40 +0100 (Fri, 16 Nov 2012) | 8 lines
  
  * src/modules/perl/modperl_apache_compat.h: Add mp_add_loaded_module
    wrapper function.
  
  * src/modules/perl/modperl_module.c (modperl_module_add): Use it.
  
  Obtained from: branches/httpd24
  Submitted by: torsten
........
  r1410299 | jorton | 2012-11-16 11:54:59 +0100 (Fri, 16 Nov 2012) | 2 lines
  
  Revert change accidentally included in r1410298.
........
  r1410314 | jorton | 2012-11-16 12:53:32 +0100 (Fri, 16 Nov 2012) | 4 lines
  
  Fix OPT_INCNOEXEC/OPT_INC_WITH_EXEC handling.
  
  Obtained from: branches/httpd24
........
  r1410316 | jorton | 2012-11-16 13:00:57 +0100 (Fri, 16 Nov 2012) | 5 lines
  
  * src/modules/perl/modperl_config.c (svav_getstr): Adjust for 2.4 API.
  
  Obtained from: branches/httpd24
  Submitted by: torsten
........
  r1410327 | jorton | 2012-11-16 14:06:50 +0100 (Fri, 16 Nov 2012) | 5 lines
  
  CScan gets rather confused if cpp's line number markers appear in the middle
  of a function declaration
  
  Submitted by: sf
........
  r1410329 | jorton | 2012-11-16 14:08:05 +0100 (Fri, 16 Nov 2012) | 4 lines
  
  Ignore more exports from 2.4/trunk which break "make source_scan".
  
  Submitted by: sf
........
  r1410343 | jorton | 2012-11-16 14:51:25 +0100 (Fri, 16 Nov 2012) | 5 lines
  
  * lib/Apache2/ParseSource.pm (include_dirs): Pick up APR include dir
    iff different to httpd include dir.
  
  Submitted by: Jan Kaluza <jkaluza redhat.com>, jorton
........
  r1410345 | jorton | 2012-11-16 15:04:59 +0100 (Fri, 16 Nov 2012) | 5 lines
  
  * src/modules/perl/modperl_apr_includes.h: Pick up new APR-util error
    codes.
  
  Submitted by: Jan Kaluza <jkaluza redhat.com>, jorton
........
  r1410400 | jorton | 2012-11-16 16:35:54 +0100 (Fri, 16 Nov 2012) | 6 lines
  
  * xs/Apache2/Log/Apache2__Log.h,
    src/modules/perl/modperl_apache_compat.h: Adapt logging for 2.4 API.
  
  Obtained from: branches/httpd24
  Submitted by: torsten
........
  r1410407 | jorton | 2012-11-16 16:44:08 +0100 (Fri, 16 Nov 2012) | 4 lines
  
  * lib/ModPerl/Code.pm: Add another constant for 2.4.
  
  Submitted by: sf
........
  r1410425 | jorton | 2012-11-16 17:09:40 +0100 (Fri, 16 Nov 2012) | 2 lines
  
  * lib/Apache2/ParseSource.pm: Pick up PROXYREQ_ constants.
........
  r1410427 | jorton | 2012-11-16 17:14:47 +0100 (Fri, 16 Nov 2012) | 5 lines
  
  Fix use of unixd_conifg for 2.4.
  
  Obtained from: branches/httpd24
  Submitted by: torsten
........
  r1419582 | jorton | 2012-12-10 18:01:24 +0100 (Mon, 10 Dec 2012) | 4 lines
  
  * lib/ModPerl/TypeMap.pm (typedefs_code, sv_convert_code):
    Produce output in sorted order for ease of diff across
    invocations.
........


git-svn-id: https://svn.apache.org/repos/asf/perl/modperl/branches/httpd24@1448022 13f79535-47bb-0310-9956-ffa450edef68
* t/response/TestAPI/aplog.pm: adjust test to new error log format

Submitted by: sf


git-svn-id: https://svn.apache.org/repos/asf/perl/modperl/branches/httpd24@1448033 13f79535-47bb-0310-9956-ffa450edef68
* xs/maps/modperl_types.map: Add U16 type to make 'make xs_generate' happy

Submitted by: sf


git-svn-id: https://svn.apache.org/repos/asf/perl/modperl/branches/httpd24@1448037 13f79535-47bb-0310-9956-ffa450edef68
* lib/ModPerl/CScan.pm: Parse inline C functions in CScan
* lib/Apache2/ParseSource.pm: Return also inline functions in get_functions()



git-svn-id: https://svn.apache.org/repos/asf/perl/modperl/branches/httpd24@1448039 13f79535-47bb-0310-9956-ffa450edef68
* xs/APR/APR/Makefile.PL: Link against aprutil-1. This is workaround
  for Apache2:Build issue.



git-svn-id: https://svn.apache.org/repos/asf/perl/modperl/branches/httpd24@1448043 13f79535-47bb-0310-9956-ffa450edef68
* xs/APR/Socket/APR__Socket.h: Rename 'sock' to 'socket' to fix compilation



git-svn-id: https://svn.apache.org/repos/asf/perl/modperl/branches/httpd24@1448045 13f79535-47bb-0310-9956-ffa450edef68
* lib/Apache2/ParseSource.pm: Do not CScan expat and byteswap headers, CScan
  cannot parse them



git-svn-id: https://svn.apache.org/repos/asf/perl/modperl/branches/httpd24@1448051 13f79535-47bb-0310-9956-ffa450edef68
* t/conf/extra.conf.in: Set DefaultRuntimeDir



git-svn-id: https://svn.apache.org/repos/asf/perl/modperl/branches/httpd24@1448052 13f79535-47bb-0310-9956-ffa450edef68
* xs/ModPerl/Const/Const.xs: Define perl_module to fix Const.so loading problem



git-svn-id: https://svn.apache.org/repos/asf/perl/modperl/branches/httpd24@1448056 13f79535-47bb-0310-9956-ffa450edef68
* t/response/TestDirective/cmdparms.pm: Disable LimitExcept test, it can be used
  only in Directory with httpd-2.4



git-svn-id: https://svn.apache.org/repos/asf/perl/modperl/branches/httpd24@1448057 13f79535-47bb-0310-9956-ffa450edef68
* xs/maps/apache2_functions.map: Add function for ServerRec::loglevel
* xs/Apache2/ServerUtil/Apache2__ServerUtil.h: port ServerRec::loglevel to
  httpd-2.4


git-svn-id: https://svn.apache.org/repos/asf/perl/modperl/branches/httpd24@1448060 13f79535-47bb-0310-9956-ffa450edef68
Add new authz/authn API defined in httpd-2.4. It adds new directives
PerlAddAuthzProvider/PerlAddAuthnProvider to register providers and
RequestUtil::register_auth_provider method.

This commit is initial try to port this new API to mod_perl and it definitely
needs a review.



git-svn-id: https://svn.apache.org/repos/asf/perl/modperl/branches/httpd24@1448098 13f79535-47bb-0310-9956-ffa450edef68
* t/response/TestAPI/access2.pm: Port the test to new authz/authn API introduced
  in httpd-2.4



git-svn-id: https://svn.apache.org/repos/asf/perl/modperl/branches/httpd24@1448100 13f79535-47bb-0310-9956-ffa450edef68
* xs/Apache2/Access/Apache2__Access.h: return 'none' if RequestRec::auth_type
 is not set to stay compatible with older mod_perl.



git-svn-id: https://svn.apache.org/repos/asf/perl/modperl/branches/httpd24@1448104 13f79535-47bb-0310-9956-ffa450edef68