perl-modperl-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject svn commit: r267280 [1/2] - in /perl/modperl/branches/clone-skip-unstable: ./ ModPerl-Registry/lib/ModPerl/ ModPerl-Registry/t/ lib/Apache2/ lib/Apache2/PerlSections/ lib/ModPerl/ src/modules/perl/ t/apache/ t/api/ t/compat/ t/conf/ t/directive/ t/filt...
Date Fri, 02 Sep 2005 19:26:45 GMT
Author: stas
Date: Fri Sep  2 12:25:12 2005
New Revision: 267280

URL: http://svn.apache.org/viewcvs?rev=267280&view=rev
Log:
sync with the trunk

Added:
    perl/modperl/branches/clone-skip-unstable/t/filter/TestFilter/in_str_declined_read.pm
      - copied unchanged from r266276, perl/modperl/trunk/t/filter/TestFilter/in_str_declined_read.pm
    perl/modperl/branches/clone-skip-unstable/t/filter/in_str_declined_read.t
      - copied unchanged from r266276, perl/modperl/trunk/t/filter/in_str_declined_read.t
Removed:
    perl/modperl/branches/clone-skip-unstable/todo/apache2_rename
Modified:
    perl/modperl/branches/clone-skip-unstable/   (props changed)
    perl/modperl/branches/clone-skip-unstable/Changes
    perl/modperl/branches/clone-skip-unstable/Makefile.PL
    perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/lib/ModPerl/RegistryCooker.pm
    perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/lib/ModPerl/RegistryLoader.pm
    perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/206.t
    perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/304.t
    perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/404.t
    perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/cgi.t
    perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/closure.t
    perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/flush.t
    perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/perlrun_extload.t
    perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/redirect.t
    perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/special_blocks.t
    perl/modperl/branches/clone-skip-unstable/lib/Apache2/Build.pm
    perl/modperl/branches/clone-skip-unstable/lib/Apache2/ParseSource.pm
    perl/modperl/branches/clone-skip-unstable/lib/Apache2/PerlSections.pm
    perl/modperl/branches/clone-skip-unstable/lib/Apache2/PerlSections/Dump.pm
    perl/modperl/branches/clone-skip-unstable/lib/Apache2/Reload.pm
    perl/modperl/branches/clone-skip-unstable/lib/Apache2/Resource.pm
    perl/modperl/branches/clone-skip-unstable/lib/Apache2/SizeLimit.pm
    perl/modperl/branches/clone-skip-unstable/lib/Apache2/Status.pm
    perl/modperl/branches/clone-skip-unstable/lib/Apache2/compat.pm
    perl/modperl/branches/clone-skip-unstable/lib/Apache2/porting.pm
    perl/modperl/branches/clone-skip-unstable/lib/ModPerl/BuildMM.pm
    perl/modperl/branches/clone-skip-unstable/lib/ModPerl/BuildOptions.pm
    perl/modperl/branches/clone-skip-unstable/lib/ModPerl/CScan.pm
    perl/modperl/branches/clone-skip-unstable/lib/ModPerl/Code.pm
    perl/modperl/branches/clone-skip-unstable/lib/ModPerl/FunctionMap.pm
    perl/modperl/branches/clone-skip-unstable/lib/ModPerl/MM.pm
    perl/modperl/branches/clone-skip-unstable/lib/ModPerl/Manifest.pm
    perl/modperl/branches/clone-skip-unstable/lib/ModPerl/MapUtil.pm
    perl/modperl/branches/clone-skip-unstable/lib/ModPerl/StructureMap.pm
    perl/modperl/branches/clone-skip-unstable/lib/ModPerl/TypeMap.pm
    perl/modperl/branches/clone-skip-unstable/lib/ModPerl/WrapXS.pm
    perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_filter.c
    perl/modperl/branches/clone-skip-unstable/t/apache/content_length_header.t
    perl/modperl/branches/clone-skip-unstable/t/api/internal_redirect.t
    perl/modperl/branches/clone-skip-unstable/t/api/lookup_uri.t
    perl/modperl/branches/clone-skip-unstable/t/compat/request_body.t
    perl/modperl/branches/clone-skip-unstable/t/conf/modperl_extra.pl
    perl/modperl/branches/clone-skip-unstable/t/conf/post_config_startup.pl
    perl/modperl/branches/clone-skip-unstable/t/directive/setupenv.t
    perl/modperl/branches/clone-skip-unstable/t/filter/TestFilter/in_bbs_body.pm
    perl/modperl/branches/clone-skip-unstable/t/filter/TestFilter/in_bbs_consume.pm
    perl/modperl/branches/clone-skip-unstable/t/filter/TestFilter/in_bbs_inject_header.pm
    perl/modperl/branches/clone-skip-unstable/t/filter/TestFilter/in_bbs_msg.pm
    perl/modperl/branches/clone-skip-unstable/t/filter/TestFilter/in_bbs_underrun.pm
    perl/modperl/branches/clone-skip-unstable/t/filter/TestFilter/out_bbs_basic.pm
    perl/modperl/branches/clone-skip-unstable/t/filter/TestFilter/out_bbs_ctx.pm
    perl/modperl/branches/clone-skip-unstable/t/filter/TestFilter/out_bbs_filebucket.pm
    perl/modperl/branches/clone-skip-unstable/t/filter/TestFilter/out_str_buffer.pm
    perl/modperl/branches/clone-skip-unstable/t/filter/out_bbs_filebucket.t
    perl/modperl/branches/clone-skip-unstable/t/filter/out_str_subreq_default.t
    perl/modperl/branches/clone-skip-unstable/t/hooks/TestHooks/authen_basic.pm
    perl/modperl/branches/clone-skip-unstable/t/hooks/TestHooks/authz.pm
    perl/modperl/branches/clone-skip-unstable/t/hooks/TestHooks/push_handlers_anon.pm
    perl/modperl/branches/clone-skip-unstable/t/hooks/TestHooks/startup.pm
    perl/modperl/branches/clone-skip-unstable/t/hooks/hookrun.t
    perl/modperl/branches/clone-skip-unstable/t/lib/TestAPRlib/string.pm
    perl/modperl/branches/clone-skip-unstable/t/lib/TestAPRlib/table.pm
    perl/modperl/branches/clone-skip-unstable/t/lib/TestAPRlib/uri.pm
    perl/modperl/branches/clone-skip-unstable/t/lib/TestAPRlib/util.pm
    perl/modperl/branches/clone-skip-unstable/t/lib/TestCommon/FilterDebug.pm
    perl/modperl/branches/clone-skip-unstable/t/lib/TestCommon/SameInterp.pm
    perl/modperl/branches/clone-skip-unstable/t/lib/TestCommon/TiePerlSection.pm
    perl/modperl/branches/clone-skip-unstable/t/lib/TestExit/FromPerlModule.pm
    perl/modperl/branches/clone-skip-unstable/t/modperl/setupenv2.t
    perl/modperl/branches/clone-skip-unstable/t/protocol/TestProtocol/eliza.pm
    perl/modperl/branches/clone-skip-unstable/t/protocol/TestProtocol/pseudo_http.pm
    perl/modperl/branches/clone-skip-unstable/t/protocol/pseudo_http.t
    perl/modperl/branches/clone-skip-unstable/t/response/TestAPI/access2.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestAPI/aplog.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestAPI/in_out_filters.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestAPI/lookup_uri2.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestAPI/request_util.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestAPI/status.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestAPR/flatten.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestAPR/perlio.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestApache/subprocess.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestApache/util.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestCompat/apache_module.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestCompat/apache_util.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestCompat/conn_authen.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestDirective/cmdparms.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestDirective/env.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestDirective/perlloadmodule.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestDirective/perlloadmodule2.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestDirective/perlloadmodule3.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestDirective/perlloadmodule4.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestDirective/perlloadmodule5.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestDirective/perlloadmodule6.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestDirective/perlloadmodule7.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestDirective/perlrequire.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestDirective/setupenv.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestError/runtime.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestModperl/cookie.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestModperl/cookie2.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestModperl/method.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestModperl/setupenv2.pm
    perl/modperl/branches/clone-skip-unstable/t/response/TestModperl/subenv.pm
    perl/modperl/branches/clone-skip-unstable/todo/bugs_build
    perl/modperl/branches/clone-skip-unstable/todo/release
    perl/modperl/branches/clone-skip-unstable/xs/APR/APR/Makefile.PL
    perl/modperl/branches/clone-skip-unstable/xs/APR/Base64/APR__Base64.h

Propchange: perl/modperl/branches/clone-skip-unstable/
------------------------------------------------------------------------------
--- merge-point (original)
+++ merge-point Fri Sep  2 12:25:12 2005
@@ -1 +1 @@
-209863
+266276

Modified: perl/modperl/branches/clone-skip-unstable/Changes
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/Changes?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/Changes (original)
+++ perl/modperl/branches/clone-skip-unstable/Changes Fri Sep  2 12:25:12 2005
@@ -12,6 +12,28 @@
 
 =item 2.0.2-dev
 
+Fix an undefined warning in DSO builds when not using MP_APXS.
+[Nikolay Ananiev <ananiev@thegdb.com>]
+
+When running Makefile.PL with the MP_MAINTAINER=1 option
+add -Wdeclaration-after-statement if we are using gcc
+version 3.3.2 or higher and its not already part of the ccopts.
+[Philip M. Gollucci, Gozer]
+
+Several fixes to Apache2::Status
+[Philip M. Gollucci]
+
+When using Apache2::Reload and ReloadDebug is set to 'On', 
+sort the output alphabetically [Philip M. Gollucci]
+
+croak in case a filter returns DECLINED after calling $f->read (as it
+is not supposed to happen) [Stas]
+
+another round of cygwin fixes [Nick *** <doink123@abv.bg>]
+
+Multiple fixes to make mod_perl 2.0 work with blead-perl (5.9.3+)
+[Stas]
+
 t/modules/reload.t would fail if run more than 3 times, breaking
 smokes [Gozer]
 

Modified: perl/modperl/branches/clone-skip-unstable/Makefile.PL
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/Makefile.PL?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/Makefile.PL (original)
+++ perl/modperl/branches/clone-skip-unstable/Makefile.PL Fri Sep  2 12:25:12 2005
@@ -389,8 +389,17 @@
     }
 
     if ($build->is_dynamic) {
-        warning "You'll need to add the following to httpd.conf:",
-                " LoadModule perl_module modules/$build->{MODPERL_LIB_DSO}\n";
+        warning
+            "You'll need to add the following to httpd.conf:",            "",
+            "  LoadModule perl_module modules/$build->{MODPERL_LIB_DSO}", "",
+            "depending on your build, mod_perl might not live in",
+            "the modules/ directory.\n";
+        if ($build->{MP_APXS}) {
+            warning 
+                "Check the results of",                                   "",
+                "  \$ $build->{MP_APXS} -q LIBEXECDIR",                   "",
+                "and adjust the LoadModule directive accordingly.\n";
+        }
     }
 
     $build->save;

Modified: perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/lib/ModPerl/RegistryCooker.pm
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/lib/ModPerl/RegistryCooker.pm?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/lib/ModPerl/RegistryCooker.pm (original)
+++ perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/lib/ModPerl/RegistryCooker.pm Fri Sep  2 12:25:12 2005
@@ -103,7 +103,7 @@
 #########################################################################
 
 sub new {
-    my($class, $r) = @_;
+    my ($class, $r) = @_;
     my $self = bless {}, $class;
     $self->init($r);
     return $self;
@@ -575,7 +575,7 @@
 
 sub shebang_to_perl {
     my $self = shift;
-    my($line) = ${ $self->{CODE} } =~ /^(.*)$/m;
+    my ($line) = ${ $self->{CODE} } =~ /^(.*)$/m;
     my @cmdline = split /\s+/, $line;
     return "" unless @cmdline;
     return "" unless shift(@cmdline) =~ /^\#!/;
@@ -617,7 +617,7 @@
 *chdir_file = \&NOP;
 
 sub chdir_file_normal {
-    my($self, $dir) = @_;
+    my ($self, $dir) = @_;
     $dir ||= File::Basename::dirname($self->{FILENAME});
     $self->debug("chdir $dir") if DEBUG & D_NOISE;
     chdir $dir or die "Can't chdir to $dir: $!";
@@ -662,7 +662,7 @@
 #########################################################################
 
 sub compile {
-    my($self, $eval) = @_;
+    my ($self, $eval) = @_;
 
     $self->debug("compiling $self->{FILENAME}") if DEBUG && D_COMPILE;
 
@@ -711,10 +711,10 @@
 #########################################################################
 
 sub install_aliases {
-    my($class, $rh_aliases) = @_;
+    my ($class, $rh_aliases) = @_;
 
     no strict 'refs';
-    while (my($k,$v) = each %$rh_aliases) {
+    while (my ($k,$v) = each %$rh_aliases) {
         if (my $sub = *{$v}{CODE}){
             *{ $class . "::$k" } = $sub;
         }
@@ -733,7 +733,7 @@
 }
 
 sub log_error {
-    my($self, $msg) = @_;
+    my ($self, $msg) = @_;
     my $class = ref $self;
 
     $self->{REQ}->log_error($msg);
@@ -763,7 +763,7 @@
 # cache_table() to point to another function, this function will fail.
 sub uncache_myself {
     my $package = scalar caller;
-    my($class) = __PACKAGE__->cache_table_common();
+    my ($class) = __PACKAGE__->cache_table_common();
 
     unless (defined $class) {
         Apache2->warn("$$: cannot figure out cache symbol table for $package");

Modified: perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/lib/ModPerl/RegistryLoader.pm
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/lib/ModPerl/RegistryLoader.pm?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/lib/ModPerl/RegistryLoader.pm (original)
+++ perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/lib/ModPerl/RegistryLoader.pm Fri Sep  2 12:25:12 2005
@@ -19,6 +19,7 @@
 
 use ModPerl::RegistryCooker ();
 use Apache2::ServerUtil ();
+use Apache2::Log ();
 use APR::Pool ();
 
 use Carp;
@@ -38,7 +39,7 @@
 }
 
 sub handler {
-    my($self, $uri, $filename, $virthost) = @_;
+    my ($self, $uri, $filename, $virthost) = @_;
 
     # set the inheritance rules at run time
     @ISA = $self->{package};
@@ -142,7 +143,7 @@
 }
 
 sub load_package {
-    my($self, $package) = @_;
+    my ($self, $package) = @_;
 
     croak "package to load wasn't specified" unless defined $package;
 
@@ -153,7 +154,7 @@
 
 sub warn {
     my $self = shift;
-    Apache2->warn(__PACKAGE__ . ": @_\n");
+    Apache2::Log->warn(__PACKAGE__ . ": @_\n");
 }
 
 1;

Modified: perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/206.t
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/206.t?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/206.t (original)
+++ perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/206.t Fri Sep  2 12:25:12 2005
@@ -5,7 +5,7 @@
 use Apache::TestUtil;
 use Apache::TestRequest qw(GET);
 
-plan tests => 2, need 'mod_alias.c';
+plan tests => 2, need [qw(mod_alias.c HTML::HeadParser)];
 
 my $url = "/registry/206.pl";
 my $res = GET($url);

Modified: perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/304.t
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/304.t?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/304.t (original)
+++ perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/304.t Fri Sep  2 12:25:12 2005
@@ -5,7 +5,7 @@
 use Apache::TestUtil;
 use Apache::TestRequest qw(GET);
 
-plan tests => 10, need 'mod_alias.c';
+plan tests => 10, need [qw(mod_alias.c HTML::HeadParser)];
 
 my $url = "/registry/304.pl";
 
@@ -42,7 +42,7 @@
         'Thu Juk 99 00:00:00 9999 FUK'  => "bogus If-Modified-Since #2",
     );
     my $received = '<html><head></head><body>Test</body></html>';
-    while ( my($if_modified_since, $debug) = each %dates) {
+    while ( my ($if_modified_since, $debug) = each %dates) {
         my $res = GET($url, 'If-Modified-Since' => $if_modified_since);
         t_debug "If-Modified-Since $if_modified_since";
         ok t_cmp(

Modified: perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/404.t
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/404.t?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/404.t (original)
+++ perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/404.t Fri Sep  2 12:25:12 2005
@@ -5,7 +5,7 @@
 use Apache::TestUtil;
 use Apache::TestRequest qw(GET_BODY GET);
 
-plan tests => 2, need 'mod_alias.c';
+plan tests => 2, need [qw(mod_alias.c HTML::HeadParser)];
 
 {
     t_client_log_error_is_expected();

Modified: perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/cgi.t
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/cgi.t?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/cgi.t (original)
+++ perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/cgi.t Fri Sep  2 12:25:12 2005
@@ -5,7 +5,8 @@
 use Apache::TestUtil;
 use Apache::TestRequest qw(GET);
 
-plan tests => 2, need 'mod_alias.c', need_min_module_version CGI => 3.08;
+plan tests => 2, need [qw(mod_alias.c HTML::HeadParser)],
+    need_min_module_version CGI => 3.08;
 
 my $url = "/registry/cgi.pl";
 my $res = GET $url;

Modified: perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/closure.t
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/closure.t?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/closure.t (original)
+++ perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/closure.t Fri Sep  2 12:25:12 2005
@@ -17,7 +17,7 @@
 
 my @modules = qw(registry registry_bb perlrun);
 
-plan tests => 6, need 'mod_alias.c';
+plan tests => 6, need [qw(mod_alias.c HTML::HeadParser)];
 
 my $cfg = Apache::Test::config();
 

Modified: perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/flush.t
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/flush.t?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/flush.t (original)
+++ perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/flush.t Fri Sep  2 12:25:12 2005
@@ -5,7 +5,7 @@
 use Apache::TestUtil;
 use Apache::TestRequest qw(GET_BODY);
 
-plan tests => 1, need 'deflate', 'mod_alias.c',
+plan tests => 1, need [qw(mod_alias.c deflate HTML::HeadParser)],
     need_min_module_version("Compress::Zlib", "1.09"),
     need_min_apache_version("2.0.48");
 # it requires httpd 2.0.48 because of the bug in mod_deflate:

Modified: perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/perlrun_extload.t
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/perlrun_extload.t?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/perlrun_extload.t (original)
+++ perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/perlrun_extload.t Fri Sep  2 12:25:12 2005
@@ -6,7 +6,7 @@
 use Apache::TestRequest qw(GET);
 use TestCommon::SameInterp;
 
-plan tests => 2, need 'mod_alias.c';
+plan tests => 2, need [qw(mod_alias.c HTML::HeadParser)];
 
 my $url = "/same_interp/perlrun/perlrun_extload.pl";
 my $same_interp = Apache::TestRequest::same_interp_tie($url);

Modified: perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/redirect.t
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/redirect.t?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/redirect.t (original)
+++ perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/redirect.t Fri Sep  2 12:25:12 2005
@@ -7,7 +7,7 @@
 
 use Apache::TestUtil qw(t_catfile_apache);
 
-plan tests => 4, need 'mod_alias.c', need_lwp;
+plan tests => 4, need [qw(mod_alias.c HTML::HeadParser)], need_lwp;
 
 # need LWP to handle redirects
 my $base_url = "/registry/redirect.pl";

Modified: perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/special_blocks.t
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/special_blocks.t?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/special_blocks.t (original)
+++ perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/special_blocks.t Fri Sep  2 12:25:12 2005
@@ -16,7 +16,7 @@
 
 my @aliases = sort keys %modules;
 
-plan tests => @aliases * 4, need 'mod_alias.c';
+plan tests => @aliases * 4, need [qw(mod_alias.c HTML::HeadParser)];
 
 {
     # PerlRun always run BEGIN/END since it's never cached

Modified: perl/modperl/branches/clone-skip-unstable/lib/Apache2/Build.pm
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/lib/Apache2/Build.pm?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/lib/Apache2/Build.pm (original)
+++ perl/modperl/branches/clone-skip-unstable/lib/Apache2/Build.pm Fri Sep  2 12:25:12 2005
@@ -154,7 +154,7 @@
     return $path unless $self->{MP_AP_DESTDIR};
 
     if (WIN32) {
-        my($dest_vol, $dest_dir) = splitpath $self->{MP_AP_DESTDIR}, 1;
+        my ($dest_vol, $dest_dir) = splitpath $self->{MP_AP_DESTDIR}, 1;
         my $real_dir = (splitpath $path)[1];
 
         $path = catpath $dest_vol, catdir($dest_dir, $real_dir), '';
@@ -308,11 +308,30 @@
     $self->{'httpd'} ||= $httpd;
     push @Apache::TestMM::Argv, ('httpd' => $self->{'httpd'});
 
-    my $mplib = "$self->{MP_LIBNAME}$Config{lib_ext}";
-    my $mplibpath = catfile($self->{cwd}, qw(src modules perl), $mplib);
+    my $mplibpath = '';
+    my $ldopts = $self->ldopts;
+    
+    if (CYGWIN) {
+        # Cygwin's httpd port links its modules into httpd2core.dll, instead of httpd.exe.
+        # In this case, we have a problem, because libtool doesn't want to include
+        # static libs (.a) into a dynamic lib (.dll). Workaround this by setting
+        # mod_perl.a as a linker argument (including all other flags and libs).
+        my $mplib  = "$self->{MP_LIBNAME}$Config{lib_ext}";
+        
+        $ldopts = join ' ', 
+            '--export-all-symbols',
+            "$self->{cwd}/src/modules/perl/$mplib",
+            $ldopts;
+        
+        $ldopts =~ s/(\S+)/-Wl,$1/g;
+        
+    } else {
+        my $mplib  = "$self->{MP_LIBNAME}$Config{lib_ext}";
+        $mplibpath = catfile($self->{cwd}, qw(src modules perl), $mplib);
+    }
 
     local $ENV{BUILTIN_LIBS} = $mplibpath;
-    local $ENV{AP_LIBS} = $self->ldopts;
+    local $ENV{AP_LIBS} = $ldopts;
     local $ENV{MODLIST} = 'perl';
 
     #XXX: -Wall and/or -Werror at httpd configure time breaks things
@@ -415,7 +434,7 @@
     my $self = shift;
     my $xlibs = "";
 
-    my($path) = $self->find_dlfile('Xau', @Xlib);
+    my ($path) = $self->find_dlfile('Xau', @Xlib);
     if ($path) {
         $xlibs = "-L$path -lXau";
     }
@@ -436,7 +455,7 @@
 }
 
 sub ldopts {
-    my($self) = @_;
+    my ($self) = @_;
 
     my $config = tied %Config;
     my $ldflags = $config->{ldflags};
@@ -469,10 +488,6 @@
         $ldopts .= $self->gtop_ldopts;
     }
 
-    if (CYGWIN && $self->is_dynamic) {
-        $ldopts .= join ' ', '', $self->apru_link_flags;
-    }
-
     $config->{ldflags} = $ldflags; #reset
 
     # on Irix mod_perl.so needs to see the libperl.so symbols, which
@@ -493,7 +508,7 @@
 $Wall .= " -Werror" if $] >= 5.006002;
 
 sub ap_ccopts {
-    my($self) = @_;
+    my ($self) = @_;
     my $ccopts = "-DMOD_PERL";
 
     if ($self->{MP_USE_GTOP}) {
@@ -508,6 +523,12 @@
             $ccopts .= " $Wall -DAP_DEBUG";
             $ccopts .= " -DAP_HAVE_DESIGNATED_INITIALIZER";
         }
+
+        if ($self->has_gcc_version('3.3.2') && 
+            $ccopts !~ /declaration-after-statement/) {
+            debug "Adding -Wdeclaration-after-statement to ccopts";
+            $ccopts .= " -Wdeclaration-after-statement";
+        }
     }
 
     if ($self->{MP_COMPAT_1X}) {
@@ -540,6 +561,31 @@
     $ccopts;
 }
 
+sub has_gcc_version {
+    my $self = shift;
+    my $requested_version = shift;
+
+    my $has_version = $self->perl_config('gccversion');
+
+    return 0 unless $has_version;
+
+    my @tuples = split /\./, $has_version, 3;
+    my @r_tuples = split /\./, $requested_version, 3;
+    
+    return cmp_tuples(\@tuples, \@r_tuples) == 1;
+}
+
+sub cmp_tuples {
+    my ($num_a, $num_b) = @_;
+
+    while (@$num_a && @$num_b) {
+        my $cmp = shift @$num_a <=> shift @$num_b;
+        return $cmp if $cmp;
+    }
+
+    return @$num_a <=> @$num_b;
+}
+    
 sub perl_ccopts {
     my $self = shift;
 
@@ -576,7 +622,7 @@
 # XXX: there could be more, but this is just for cosmetics
 my %cflags_dups = map { $_ => 1 } qw(-D_GNU_SOURCE -D_REENTRANT);
 sub ccopts {
-    my($self) = @_;
+    my ($self) = @_;
 
     my $cflags = $self->perl_ccopts . ExtUtils::Embed::perl_inc() .
                  $self->ap_ccopts;
@@ -602,7 +648,7 @@
 }
 
 sub perl_config_optimize {
-    my($self, $val) = @_;
+    my ($self, $val) = @_;
 
     $val ||= $Config{optimize};
 
@@ -614,7 +660,7 @@
 }
 
 sub perl_config_ld {
-    my($self, $val) = @_;
+    my ($self, $val) = @_;
 
     $val ||= $Config{ld};
 
@@ -622,7 +668,7 @@
 }
 
 sub perl_config_lddlflags {
-    my($self, $val) = @_;
+    my ($self, $val) = @_;
 
     if ($self->{MP_DEBUG}) {
         if (MSVC) {
@@ -663,7 +709,7 @@
 }
 
 sub perl_config {
-    my($self, $key) = @_;
+    my ($self, $key) = @_;
 
     my $val = $Config{$key} || '';
 
@@ -692,14 +738,14 @@
 }
 
 sub find_dlfile {
-    my($self, $name) = (shift, shift);
+    my ($self, $name) = (shift, shift);
 
     require DynaLoader;
     require AutoLoader; #eek
 
     my $found = 0;
     my $loc = "";
-    my(@path) = ($self->libpth, @_);
+    my (@path) = ($self->libpth, @_);
 
     for (@path) {
         if ($found = DynaLoader::dl_findfile($_, "-l$name")) {
@@ -712,7 +758,7 @@
 }
 
 sub find_dlfile_maybe {
-    my($self, $name) = @_;
+    my ($self, $name) = @_;
 
     my $path = $self->libpth;
 
@@ -727,7 +773,7 @@
 }
 
 sub lib_check {
-    my($self, $name) = @_;
+    my ($self, $name) = @_;
     return unless $self->perl_config('libs') =~ /$name/;
 
     return if $self->find_dlfile($name);
@@ -746,24 +792,24 @@
 #--- user interaction ---
 
 sub prompt {
-    my($self, $q, $default) = @_;
+    my ($self, $q, $default) = @_;
     return $default if $self->{MP_PROMPT_DEFAULT};
     require ExtUtils::MakeMaker;
     ExtUtils::MakeMaker::prompt($q, $default);
 }
 
 sub prompt_y {
-    my($self, $q) = @_;
+    my ($self, $q) = @_;
     $self->prompt($q, 'y') =~ /^y/i;
 }
 
 sub prompt_n {
-    my($self, $q) = @_;
+    my ($self, $q) = @_;
     $self->prompt($q, 'n') =~ /^n/i;
 }
 
 sub phat_warn {
-    my($self, $msg, $abort) = @_;
+    my ($self, $msg, $abort) = @_;
     my $level = $abort ? 'ERROR' : 'WARNING';
     warn <<EOF;
 ************* $level *************
@@ -802,7 +848,7 @@
     }
 
     return bless {}, (ref($self) || $self) if $@;
-    return Apache2::BuildConfig::->new;
+    return Apache2::BuildConfig->new;
 }
 
 sub new {
@@ -835,7 +881,7 @@
 }
 
 sub default_file {
-    my($self, $name, $override) = @_;
+    my ($self, $name, $override) = @_;
     my $key = join '_', 'file', $name;
     $self->{$key} ||= ($override || $default_files{$name});
 }
@@ -856,7 +902,7 @@
 }
 
 sub save_ldopts {
-    my($self, $file) = @_;
+    my ($self, $file) = @_;
 
     $file ||= $self->default_file('ldopts', $file);
     my $ldopts = $self->ldopts;
@@ -872,7 +918,7 @@
 }
 
 sub save {
-    my($self, $file) = @_;
+    my ($self, $file) = @_;
 
     delete $INC{$bpm};
 
@@ -926,7 +972,7 @@
 }
 
 sub dir {
-    my($self, $dir) = @_;
+    my ($self, $dir) = @_;
 
     if ($dir) {
         for (qw(ap_includedir)) {
@@ -988,7 +1034,7 @@
 }
 
 sub ap_includedir  {
-    my($self, $d) = @_;
+    my ($self, $d) = @_;
 
     return $self->{ap_includedir}
       if $self->{ap_includedir} and -d $self->{ap_includedir};
@@ -1048,15 +1094,15 @@
 }
 
 sub apr_generation {
-    my($self) = @_;
-    return $self->httpd_version_as_int =~ m/21\d+/ ? 1 : 0;
+    my ($self) = @_;
+    return $self->httpd_version_as_int =~ m/2[1-9]\d+/ ? 1 : 0;
 }
 
 # returns an array of apr/apu linking flags (--link-ld --libs) if found
 # an empty array otherwise
 my @apru_link_flags = ();
 sub apru_link_flags {
-    my($self) = @_;
+    my ($self) = @_;
 
     return @apru_link_flags if @apru_link_flags;
 
@@ -1122,7 +1168,7 @@
             if ($self->{MP_AP_CONFIGURE} &&
                 $self->{MP_AP_CONFIGURE} =~ /--with-${what_long}=(\S+)/) {
                 my $dir = $1;
-                $dir =~ s/$config$// unless -d $dir;
+                $dir = dirname $dir if -f $dir;
                 push @tries, grep -d $_, $dir, catdir $dir, 'bin';
             }
         }
@@ -1206,7 +1252,7 @@
 #--- parsing apache *.h files ---
 
 sub mmn_eq {
-    my($class, $dir) = @_;
+    my ($class, $dir) = @_;
 
     return 1 if WIN32; #just assume, till Apache2::Build works under win32
 
@@ -1272,20 +1318,20 @@
 }
 
 sub httpd_version_as_int {
-    my($self, $dir) = @_;
+    my ($self, $dir) = @_;
     my $v = $self->httpd_version($dir);
     fold_dots($v);
 }
 
 sub httpd_version_cache {
-    my($self, $dir, $v) = @_;
+    my ($self, $dir, $v) = @_;
     return '' unless $dir;
     $self->{httpd_version}->{$dir} = $v if $v;
     $self->{httpd_version}->{$dir};
 }
 
 sub httpd_version {
-    my($self, $dir) = @_;
+    my ($self, $dir) = @_;
 
     return unless $dir = $self->ap_includedir($dir);
 
@@ -1357,7 +1403,7 @@
     while (<$fh>) {
         next unless s/^\#define\s+APR_((HAVE|HAS|USE)_\w+)/$1/;
         chomp;
-        my($name, $val) = split /\s+/, $_, 2;
+        my ($name, $val) = split /\s+/, $_, 2;
         next unless $wanted_apr_config{$name};
         $val =~ s/\s+$//;
         next unless $val =~ /^\d+$/;
@@ -1370,7 +1416,7 @@
 #--- generate Makefile ---
 
 sub canon_make_attr {
-    my($self, $name) = (shift, shift);
+    my ($self, $name) = (shift, shift);
 
     my $attr = join '_', 'MODPERL', uc $name;
     $self->{$attr} = "@_";
@@ -1393,7 +1439,7 @@
 }
 
 sub make_xs {
-    my($self, $fh) = @_;
+    my ($self, $fh) = @_;
 
     print $fh $self->canon_make_attr(xsubpp => $self->xsubpp);
 
@@ -1402,7 +1448,7 @@
     my @files;
     my @xs_targ;
 
-    while (my($name, $xs) = each %{ $self->{XS} }) {
+    while (my ($name, $xs) = each %{ $self->{XS} }) {
         #Foo/Bar.xs => Foo_Bar.c
         (my $c = $xs) =~ s:.*?WrapXS/::;
         $c =~ s:/:_:g;
@@ -1458,7 +1504,7 @@
 my @mm_init_vars = (BASEEXT => '');
 
 sub make_tools {
-    my($self, $fh) = @_;
+    my ($self, $fh) = @_;
 
     for (@perl_config_pm) {
         print $fh $self->canon_make_attr($_, $self->perl_config($_));
@@ -1537,6 +1583,21 @@
         "\t" . '$(MODPERL_RANLIB) $@';
 }
 
+sub dynamic_link_cygwin {
+    my $self = shift;
+    return <<'EOF';
+$(MODPERL_LIBNAME).$(MODPERL_DLEXT): $(MODPERL_PIC_OBJS)
+	$(MODPERL_RM_F) $@
+	$(MODPERL_CC) -shared -o $@ \
+	-Wl,--out-implib=$(MODPERL_LIBNAME).dll.a \
+	-Wl,--export-all-symbols -Wl,--enable-auto-import -Wl,--stack,8388608 \
+	$(MODPERL_PIC_OBJS) \
+	$(MODPERL_LDDLFLAGS) $(MODPERL_LDOPTS) \
+	$(MODPERL_AP_LIBS)
+	$(MODPERL_RANLIB) $@
+EOF
+}
+
 sub dynamic_link {
     my $self = shift;
     my $link = \&{"dynamic_link_$^O"};
@@ -1544,6 +1605,34 @@
     $link->($self);
 }
 
+# Returns the link flags for the apache shared core library
+my $apache_corelib_cygwin;
+sub apache_corelib_cygwin {
+    return $apache_corelib_cygwin if $apache_corelib_cygwin;
+    
+    my $self = shift;
+    my $mp_src = "$self->{cwd}/src/modules/perl";
+    my $core = 'httpd2core';
+    
+    # There's a problem with user-installed perl on cygwin.
+    # MakeMaker doesn't know about the .dll.a libs and warns
+    # about missing -lhttpd2core. "Fix" it by copying
+    # the lib and adding .a suffix.
+    # For the static build create a soft link, because libhttpd2core.dll.a
+    # doesn't exist at this time.
+    if ($self->is_dynamic) {
+        my $libpath = $self->apxs(-q => 'exp_libdir');
+        File::Copy::copy("$libpath/lib$core.dll.a", "$mp_src/lib$core.a");
+    } else {
+        my $libpath = catdir($self->{MP_AP_PREFIX}, '.libs');
+        mkdir $libpath unless -d $libpath;
+        qx{touch $libpath/lib$core.dll.a && \
+        ln -fs $libpath/lib$core.dll.a $mp_src/lib$core.a};
+    }
+    
+    $apache_corelib_cygwin = "-L$mp_src -l$core";
+}
+
 sub apache_libs_MSWin32 {
     my $self = shift;
     my $prefix = $self->apxs(-q => 'PREFIX') || $self->dir;
@@ -1551,6 +1640,11 @@
     "@libs";
 }
 
+sub apache_libs_cygwin {
+    my $self = shift;
+    join ' ', $self->apache_corelib_cygwin, $self->apru_link_flags;
+}
+
 sub apache_libs {
     my $self = shift;
     my $libs = \&{"apache_libs_$^O"};
@@ -1560,16 +1654,13 @@
 
 sub modperl_libs_MSWin32 {
     my $self = shift;
-    # mod_perl.lib will be installed into MP_AP_PREFIX/lib
-    # for use by 3rd party xs modules
     "$self->{cwd}/src/modules/perl/$self->{MP_LIBNAME}.lib";
 }
 
 sub modperl_libs_cygwin {
      my $self = shift;
-     return $self->is_dynamic
-         ? "-L$self->{cwd}/src/modules/perl -l$self->{MP_LIBNAME}"
-         : $self->modperl_static_libs_cygwin;
+     return '' unless $self->is_dynamic;
+     return "-L$self->{cwd}/src/modules/perl -l$self->{MP_LIBNAME}";
 }
 
 sub modperl_libs {
@@ -1579,35 +1670,23 @@
     $libs->($self);
 }
 
-my $modperl_static_libs_cygwin = '';
-sub modperl_static_libs_cygwin {
+sub modperl_libpath_MSWin32 {
     my $self = shift;
+    # mod_perl.lib will be installed into MP_AP_PREFIX/lib
+    # for use by 3rd party xs modules
+    "$self->{cwd}/src/modules/perl/$self->{MP_LIBNAME}.lib";
+}
 
-    return $modperl_static_libs_cygwin if $modperl_static_libs_cygwin;
-
-    my $dyna_filepath = catdir $self->perl_config('archlibexp'),
-        'auto/DynaLoader/DynaLoader.a';
-    my $modperl_path  = "$self->{cwd}/src/modules/perl";
-    # Create symlink to mod_perl.a, but copy DynaLoader.a, because
-    # when running make clean the real DynaLoader.a may get deleted.
-    my $src = catfile $modperl_path, "$self->{MP_LIBNAME}.a";
-    my $dst = catfile $modperl_path, "lib$self->{MP_LIBNAME}.a";
-    # perl's link() on Cygwin seems to copy mod_perl.a to
-    # libmod_perl.a, but at this stage mod_perl.a is still a dummy lib
-    # and at the end we get nothing. whereas `ln -s` seems to create
-    # something like the shortcut on windows and it works.
-    qx{ln -s $src $dst} unless -e $dst;
-    File::Copy::copy($dyna_filepath, "$modperl_path/libDynaLoader.a");
-
-    $modperl_static_libs_cygwin = join ' ',
-        "-L$modperl_path",
-        "-l$self->{MP_LIBNAME}",
-        '-lDynaLoader',
-        $self->apru_link_flags,
-        '-L' . catdir($self->perl_config('archlibexp'), 'CORE'),
-        '-lperl';
+sub modperl_libpath_cygwin {
+    my $self = shift;
+    "$self->{cwd}/src/modules/perl/$self->{MP_LIBNAME}.dll.a";
+}
 
-    $modperl_static_libs_cygwin;
+sub modperl_libpath {
+    my $self = shift;
+    my $libpath = \&{"modperl_libpath_$^O"};
+    return "" unless defined &$libpath;
+    $libpath->($self);
 }
 
 # returns the directory and name of the aprext lib built under blib/ 
@@ -1639,7 +1718,7 @@
 
     # This is ugly, but is the only way to prevent the "undefined
     # symbols" error
-    $libs .= join ' ', '', $self->apru_link_flags,
+    $libs .= join ' ', '',
         '-L' . catdir($self->perl_config('archlibexp'), 'CORE'), '-lperl';
 
     $libs;
@@ -1682,7 +1761,7 @@
 	$(MODPERL_CP) $(MODPERL_LIB_DSO) $(DESTDIR)$(MODPERL_AP_LIBEXECDIR)
 EOI
     }
-    
+
     $install .= <<'EOI';
 # install mod_perl .h files
 	@$(MKPATH) $(DESTDIR)$(MODPERL_AP_INCLUDEDIR)
@@ -1717,7 +1796,7 @@
     #XXX short-term compat for Apache::TestConfigPerl
     $libs{shared} = $libs{dso};
 
-    while (my($type, $lib) = each %libs) {
+    while (my ($type, $lib) = each %libs) {
         print $fh $self->canon_make_attr("lib_$type", $libs{$type});
     }
 
@@ -1731,7 +1810,7 @@
 EOI
     }
 
-    if (my $libs = $self->modperl_libs) {
+    if ($self->is_dynamic && (my $libs = $self->modperl_libpath)) {
         print $fh $self->canon_make_attr('lib_location', $libs);
 
         print $fh $self->canon_make_attr('ap_libdir',
@@ -1880,17 +1959,6 @@
     $flags;
 }
 
-sub otherldflags_cygwin {
-    my $self = shift;
-    my $flags = $self->otherldflags_default;
-
-    unless ($self->{MP_STATIC_EXTS}) {
-        $flags .= join ' ', '', $self->apru_link_flags;
-    }
-
-    $flags;
-}
-
 sub typemaps {
     my $self = shift;
     my @typemaps = ();
@@ -2049,7 +2117,7 @@
 # will have to make sure to prevent any operations that may rely on
 # effects created by uselargefiles, e.g. Off_t=8 instead of Off_t=4)
 sub strip_lfs {
-    my($self, $cflags) = @_;
+    my ($self, $cflags) = @_;
     return $cflags unless $self->has_large_files_conflict();
 
     my $lf = $Config{ccflags_uselargefiles}

Modified: perl/modperl/branches/clone-skip-unstable/lib/Apache2/ParseSource.pm
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/lib/Apache2/ParseSource.pm?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/lib/Apache2/ParseSource.pm (original)
+++ perl/modperl/branches/clone-skip-unstable/lib/Apache2/ParseSource.pm Fri Sep  2 12:25:12 2005
@@ -185,7 +185,7 @@
 }
 
 sub find_includes_wanted {
-    my($wanted, $unwanted, @dirs) = @_;
+    my ($wanted, $unwanted, @dirs) = @_;
     my @includes = ();
     for my $dir (@dirs) {
         File::Find::finddepth({
@@ -265,8 +265,8 @@
 );
 
 my %defines_wanted_re;
-while (my($class, $groups) = each %defines_wanted) {
-    while (my($group, $wanted) = each %$groups) {
+while (my ($class, $groups) = each %defines_wanted) {
+    while (my ($group, $wanted) = each %$groups) {
         my $pat = join '|', @$wanted;
         $defines_wanted_re{$class}->{$group} = $pat; #qr{^($pat)};
     }
@@ -282,10 +282,10 @@
 };
 
 sub get_constants {
-    my($self) = @_;
+    my ($self) = @_;
 
     my $includes = $self->find_includes;
-    my(%constants, %seen);
+    my (%constants, %seen);
 
     for my $file (@$includes) {
         open my $fh, $file or die "open $file: $!";
@@ -312,15 +312,15 @@
 }
 
 sub handle_constant {
-    my($self, $constants) = @_;
+    my ($self, $constants) = @_;
     my $keys = keys %defines_wanted_re; #XXX broken bleedperl ?
 
     return if /^($defines_unwanted)/o;
 
-    while (my($class, $groups) = each %defines_wanted_re) {
+    while (my ($class, $groups) = each %defines_wanted_re) {
         my $keys = keys %$groups; #XXX broken bleedperl ?
 
-        while (my($group, $re) = each %$groups) {
+        while (my ($group, $re) = each %$groups) {
             next unless /^($re)/;
             push @{ $constants->{$class}->{$group} }, $_;
             return;
@@ -329,9 +329,9 @@
 }
 
 sub handle_enum {
-    my($self, $fh, $constants) = @_;
+    my ($self, $fh, $constants) = @_;
 
-    my($name, $e) = $self->parse_enum($fh);
+    my ($name, $e) = $self->parse_enum($fh);
     return unless $name;
 
     $name =~ s/^ap_//;
@@ -351,7 +351,7 @@
 
 #this should win an award for worlds lamest parser
 sub parse_enum {
-    my($self, $fh) = @_;
+    my ($self, $fh) = @_;
     my $code = $_;
     my @e;
 
@@ -404,7 +404,7 @@
     my @functions;
 
     for my $entry (@$fdecls) {
-        my($rtype, $name, $args) = @$entry;
+        my ($rtype, $name, $args) = @$entry;
         next unless $name =~ $wanted;
         next if $seen{$name}++;
         my @attr;
@@ -461,7 +461,7 @@
     my @structures;
     my $sx = qr(^struct\s+);
 
-    while (my($type, $elts) = each %$typedef_structs) {
+    while (my ($type, $elts) = each %$typedef_structs) {
         next unless $type =~ $wanted or $type =~ /($other)$/o;
 
         $type =~ s/$sx//;
@@ -512,12 +512,12 @@
 }
 
 sub write_pm {
-    my($self, $file, $name, $data) = @_;
+    my ($self, $file, $name, $data) = @_;
 
     require Data::Dumper;
     local $Data::Dumper::Indent = 1;
 
-    my($subdir) = (split '::', $name)[0];
+    my ($subdir) = (split '::', $name)[0];
 
     my $tdir = 'xs/tables/current';
     if (-d "$tdir/$subdir") {

Modified: perl/modperl/branches/clone-skip-unstable/lib/Apache2/PerlSections.pm
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/lib/Apache2/PerlSections.pm?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/lib/Apache2/PerlSections.pm (original)
+++ perl/modperl/branches/clone-skip-unstable/lib/Apache2/PerlSections.pm Fri Sep  2 12:25:12 2005
@@ -30,7 +30,7 @@
 use constant SPECIAL_PACKAGE => 'Apache2::ReadConfig';
 
 sub new {
-    my($package, @args) = @_;
+    my ($package, @args) = @_;
     return bless { @args }, ref($package) || $package;
 }
 
@@ -43,7 +43,7 @@
 sub saved      { return @saved }
 
 sub handler : method {
-    my($self, $parms, $args) = @_;
+    my ($self, $parms, $args) = @_;
 
     unless (ref $self) {
         $self = $self->new('parms' => $parms, 'args' => $args);
@@ -75,7 +75,7 @@
 }
 
 sub symdump {
-    my($self) = @_;
+    my ($self) = @_;
 
     unless ($self->{symbols}) {
         no strict;
@@ -107,12 +107,12 @@
 }
 
 sub dump_special {
-    my($self, @data) = @_;
+    my ($self, @data) = @_;
     $self->add_config(@data);
 }
 
 sub dump_any {
-    my($self, $name, $entry) = @_;
+    my ($self, $name, $entry) = @_;
     my $type = ref $entry;
 
     if ($type eq 'ARRAY') {
@@ -127,7 +127,7 @@
 }
 
 sub dump_hash {
-    my($self, $name, $hash) = @_;
+    my ($self, $name, $hash) = @_;
 
     for my $entry (sort keys %{ $hash || {} }) {
         my $item = $hash->{$entry};
@@ -145,7 +145,7 @@
 }
 
 sub dump_section {
-    my($self, $name, $loc, $hash) = @_;
+    my ($self, $name, $loc, $hash) = @_;
 
     $self->add_config("<$name $loc>\n");
 
@@ -157,7 +157,7 @@
 }
 
 sub dump_array {
-    my($self, $name, $entries) = @_;
+    my ($self, $name, $entries) = @_;
 
     for my $entry (@$entries) {
         $self->dump_entry($name, $entry);
@@ -165,7 +165,7 @@
 }
 
 sub dump_entry {
-    my($self, $name, $entry) = @_;
+    my ($self, $name, $entry) = @_;
     my $type = ref $entry;
 
     if ($type eq 'SCALAR') {
@@ -192,14 +192,14 @@
 }
 
 sub add_config {
-    my($self, $config) = @_;
+    my ($self, $config) = @_;
     return unless defined $config;
     chomp($config);
     push @{ $self->directives }, $config;
 }
 
 sub post_config {
-    my($self) = @_;
+    my ($self) = @_;
     my $errmsg = $self->parms->add_config($self->directives);
     die $errmsg if $errmsg;
 }

Modified: perl/modperl/branches/clone-skip-unstable/lib/Apache2/PerlSections/Dump.pm
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/lib/Apache2/PerlSections/Dump.pm?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/lib/Apache2/PerlSections/Dump.pm (original)
+++ perl/modperl/branches/clone-skip-unstable/lib/Apache2/PerlSections/Dump.pm Fri Sep  2 12:25:12 2005
@@ -54,12 +54,12 @@
 }
 
 sub dump_array {
-     my($self, $name, $entry) = @_;
+     my ($self, $name, $entry) = @_;
      $self->add_config(Data::Dumper->Dump([$entry], ["*$name"]));
 }
 
 sub dump_hash {
-    my($self, $name, $entry) = @_;
+    my ($self, $name, $entry) = @_;
     for my $elem (sort keys %{$entry}) {
         $self->add_config(Data::Dumper->Dump([$entry->{$elem}], ["\$$name"."{'$elem'}"])); 
     }
@@ -67,7 +67,7 @@
 }
 
 sub dump_entry {
-    my($self, $name, $entry) = @_;
+    my ($self, $name, $entry) = @_;
     
     return if not defined $entry;
     my $type = ref($entry);
@@ -84,7 +84,7 @@
 }
 
 sub dump_special {
-    my($self, @data) = @_;
+    my ($self, @data) = @_;
     
     my @dump = grep { defined } @data;
     return unless @dump;

Modified: perl/modperl/branches/clone-skip-unstable/lib/Apache2/Reload.pm
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/lib/Apache2/Reload.pm?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/lib/Apache2/Reload.pm (original)
+++ perl/modperl/branches/clone-skip-unstable/lib/Apache2/Reload.pm Fri Sep  2 12:25:12 2005
@@ -37,7 +37,7 @@
 
 sub import {
     my $class = shift;
-    my($package, $file) = (caller)[0,1];
+    my ($package, $file) = (caller)[0,1];
 
     $class->register_module($package, $file);
 }
@@ -57,7 +57,7 @@
 }
 
 sub register_module {
-    my($class, $package, $file) = @_;
+    my ($class, $package, $file) = @_;
     my $module = package_to_module($package);
 
     if ($file) {
@@ -71,7 +71,7 @@
 }
 
 sub unregister_module {
-    my($class, $package) = @_;
+    my ($class, $package) = @_;
     my $module = package_to_module($package);
     delete $INCS{$module};
 }
@@ -131,7 +131,9 @@
 
     my $ReloadDirs = ref($o) && $o->dir_config("ReloadDirectories");
     my @watch_dirs = split(/\s+/, $ReloadDirs||'');
-    while (my($key, $file) = each %Apache2::Reload::INCS) {
+    foreach my $key (sort { $a cmp $b } keys %Apache2::Reload::INCS) {
+        my $file = $Apache2::Reload::INCS{$key};
+
         next unless defined $file;
         next if @watch_dirs && !grep { $file =~ /^$_/ } @watch_dirs;
         warn "Apache2::Reload: Checking mtime of $key\n" if $DEBUG;

Modified: perl/modperl/branches/clone-skip-unstable/lib/Apache2/Resource.pm
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/lib/Apache2/Resource.pm?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/lib/Apache2/Resource.pm (original)
+++ perl/modperl/branches/clone-skip-unstable/lib/Apache2/Resource.pm Fri Sep  2 12:25:12 2005
@@ -55,7 +55,7 @@
 sub debug { print STDERR @_ if $Debug }
 
 sub install_rlimit ($$$) {
-    my($res, $soft, $hard) = @_;
+    my ($res, $soft, $hard) = @_;
 
     my $name = $res;
 
@@ -82,11 +82,11 @@
 }
 
 sub handler {
-    while (my($k, $v) = each %ENV) {
+    while (my ($k, $v) = each %ENV) {
         next unless $k =~ /^PERL_RLIMIT_(\w+)$/;
         $k = $1;
         next if $k eq "DEFAULTS";
-        my($soft, $hard) = split ":", $v, 2;
+        my ($soft, $hard) = split ":", $v, 2;
         $hard ||= $soft;
 
         my $set = install_rlimit $k, $soft, $hard;
@@ -99,7 +99,7 @@
 }
 
 sub default_handler {
-    while (my($k, $v) = each %Apache2::Resource::) {
+    while (my ($k, $v) = each %Apache2::Resource::) {
         next unless $k =~ s/^DEFAULT_/PERL_/;
         $ENV{$k} = "";
     }
@@ -114,7 +114,7 @@
 
     for my $res (keys %$lim) {
         my $val = eval "&BSD::Resource::${res}()";
-        my($soft, $hard) = getrlimit $val;
+        my ($soft, $hard) = getrlimit $val;
         (my $limit = $res) =~ s/^RLIMIT_//;
         ($soft, $hard) = ("$soft " . BM($soft), "$hard ". BM($hard))
             if $is_mb{$limit};

Modified: perl/modperl/branches/clone-skip-unstable/lib/Apache2/SizeLimit.pm
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/lib/Apache2/SizeLimit.pm?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/lib/Apache2/SizeLimit.pm (original)
+++ perl/modperl/branches/clone-skip-unstable/lib/Apache2/SizeLimit.pm Fri Sep  2 12:25:12 2005
@@ -87,7 +87,7 @@
 
 # return process size (in KB)
 sub linux_size_check {
-    my($size, $resident, $share) = (0, 0, 0);
+    my ($size, $resident, $share) = (0, 0, 0);
 
     my $file = "/proc/self/statm";
     if (open my $fh, "<$file") {
@@ -159,7 +159,7 @@
 
     $START_TIME ||= time;
 
-    my($size, $share) = $HOW_BIG_IS_IT->();
+    my ($size, $share) = $HOW_BIG_IS_IT->();
 
     if (($MAX_PROCESS_SIZE  && $size > $MAX_PROCESS_SIZE) ||
         ($MIN_SHARE_SIZE    && $share < $MIN_SHARE_SIZE)  ||

Modified: perl/modperl/branches/clone-skip-unstable/lib/Apache2/Status.pm
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/lib/Apache2/Status.pm?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/lib/Apache2/Status.pm (original)
+++ perl/modperl/branches/clone-skip-unstable/lib/Apache2/Status.pm Fri Sep  2 12:25:12 2005
@@ -28,7 +28,7 @@
 
 use Apache2::Const -compile => qw(OK);
 
-$Apache2::Status::VERSION = '3.00'; # mod_perl 2.0
+$Apache2::Status::VERSION = '4.00'; # mod_perl 2.0
 
 use constant IS_WIN32 => ($^O eq "MSWin32");
 
@@ -42,14 +42,9 @@
     env       => "Environment",
     sig       => "Signal Handlers",
     myconfig  => "Perl Configuration",
-    hooks     => "Enabled mod_perl Hooks",
 );
-# XXX: is $status{hooks} supported with any mp2 version?
-# If not, why not just remove it from the above initialization?
-delete $status{'hooks'} if $mod_perl2::VERSION >= 1.9901;
 delete $status{'sig'} if IS_WIN32;
 
-# XXX: needs porting
 if ($Apache2::PerlSections::Save) {
     $status{"section_config"} = "Perl Section Configuration";
 }
@@ -62,19 +57,19 @@
     b           => ["",                  "B",              0,    ],
     graph       => ["StatusGraph",       "B::Graph",       0.03, ],
     lexinfo     => ["StatusLexInfo",     "B::LexInfo",     0,    ],
-    xref        => ["",                  "B::Xref",        0,    ],
+    xref        => ["StatusXref",        "B::Xref",        1.01, ],
     terse       => ["StatusTerse",       "B::Terse",       0,    ],
     tersesize   => ["StatusTerseSize",   "B::TerseSize",   0,    ],
     packagesize => ["StatusPackageSize", "B::TerseSize",   0,    ],
-    peek        => ["StatusPeek",        "Apache2::Peek",   0,    ], # XXX: version?
+    peek        => ["StatusPeek",        "Apache::Peek",   1.03, ],
 );
 
 sub has {
-    my($r, $what) = @_;
+    my ($r, $what) = @_;
 
     return 0 unless exists $requires{$what};
 
-    my($opt, $module, $version) = @{ $requires{$what} };
+    my ($opt, $module, $version) = @{ $requires{$what} };
 
     (my $file = $module) =~ s|::|/|;
     $file .= ".pm";
@@ -98,13 +93,13 @@
 }
 
 sub status_config {
-    my($r, $key) = @_;
+    my ($r, $key) = @_;
     return (lc($r->dir_config($key)) eq "on") ||
         (lc($r->dir_config('StatusOptionsAll')) eq "on");
 }
 
 sub menu_item {
-    my($self, $key, $val, $sub) = @_;
+    my ($self, $key, $val, $sub) = @_;
     $status{$key} = $val;
     no strict;
     no warnings 'redefine';
@@ -112,7 +107,7 @@
 }
 
 sub handler {
-    my($r) = @_;
+    my ($r) = @_;
     my $qs = $r->args || "";
     my $sub = "status_$qs";
     no strict 'refs';
@@ -133,7 +128,7 @@
         my $uri = $r->uri;
         $r->print('<p>');
         $r->print(
-            map { qq[<a href="$uri?$_">$status{$_}</a><br>\n] } keys %status
+            map { qq[<a href="$uri?$_">$status{$_}</a><br />\n] } sort { lc $a cmp lc $b } keys %status
         );
         $r->print('</p>');
     }
@@ -149,34 +144,36 @@
     $r->content_type("text/html");
     my $v = $^V ? sprintf "v%vd", $^V : $];
     $r->print(<<"EOF");
-<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
-<html lang="en">
-<head>
-  <title>Apache2::Status</title>
-  <style type="text/css">
-  body {
-    color: #000;
-    background-color: #fff;
-  }
-  p.hdr {
-    background-color: #ddd;
-    border: 2px outset;
-    padding: 3px;
-    width: 99%;
-  }
-  </style>
-</head>
-<body>
-<p class="hdr">
-  Embedded Perl version <b>$v</b> for <b>$srv</b> process <b>$$</b>,<br>
-  running since $start
-</p>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
+  <head>
+    <title>Apache2::Status $Apache2::Status::VERSION</title>
+    <style type="text/css">
+      body {
+        color: #000;
+        background-color: #fff;
+      }
+      p.hdr {
+        background-color: #ddd;
+        border: 2px outset;
+        padding: 3px;
+        width: 99%;
+     }
+   </style>
+  </head>
+  <body>
+    <p class="hdr">
+      Embedded Perl version <b>$v</b> for <b>$srv</b> process <b>$$</b>,<br />
+      running since $start
+    </p>
 EOF
 
 }
 
 sub symdump {
-    my($r, $package) = @_;
+    my ($r, $package) = @_;
 
     return install_hint("Devel::Symdump") unless has($r, "symdump");
 
@@ -187,34 +184,18 @@
 }
 
 sub status_symdump {
-    my($r) = @_;
+    my ($r) = @_;
     [symdump($r, 'main')];
 }
 
 sub status_section_config {
-    my($r) = @_;
+    my ($r) = @_;
     require Apache2::PerlSections;
     ["<pre>", Apache2::PerlSections->dump, "</pre>"];
 }
 
-sub status_hooks {
-    my($r) = @_;
-    # XXX: hooks list access doesn't exist yet in 2.0
-    require mod_perl;
-    require mod_perl_hooks;
-    my @retval = qw(<table>);
-    my @list = mod_perl::hooks();
-    for my $hook (sort @list) {
-        my $on_off = 
-            mod_perl::hook($hook) ? "<b>Enabled</b>" : "<i>Disabled</i>";
-        push @retval, "<tr><td>$hook</td><td>$on_off</td></tr>\n";
-    }
-    push @retval, qw(</table>);
-    \@retval;
-}
-
 sub status_inc {
-    my($r) = @_;
+    my ($r) = @_;
 
     my $uri = $r->uri;
     my @retval = (
@@ -243,12 +224,12 @@
         );
     }
     push @retval, "</table>\n";
-    push @retval, "<p><b>\@INC</b> = <br>", join "<br>\n", @INC, "";
+    push @retval, "<p><b>\@INC</b> = <br />", join "<br />\n", @INC, "";
     \@retval;
 }
 
 sub status_script {
-    my($r) = @_;
+    my ($r) = @_;
 
     my @retval = (
         '<table border="1">',
@@ -267,7 +248,7 @@
 my $RegistryCache;
 
 sub registry_cache {
-    my($self, $cache) = @_;
+    my ($self, $cache) = @_;
 
     # XXX: generalize
 
@@ -276,7 +257,7 @@
 }
 
 sub get_packages_per_handler {
-    my($root, $stash) = @_;
+    my ($root, $stash) = @_;
 
     my %handlers = ();
     my @packages = get_packages($stash);
@@ -288,7 +269,7 @@
 }
 
 sub get_packages {
-    my($stash) = @_;
+    my ($stash) = @_;
 
     no strict 'refs';
     my @packages = ();
@@ -300,7 +281,7 @@
 }
 
 sub status_rgysubs {
-    my($r) = @_;
+    my ($r) = @_;
 
     local $_;
     my $uri = $r->uri;
@@ -318,7 +299,7 @@
         push @retval, "<h4>$handler:</h4>\n<p>\n";
         for (sort @{ $handlers{$handler} }) {
             my $full = join '::', $root, $handler, $_;
-            push @retval, qq(<a href="$uri?$full">$_</a>\n), "<br>";
+            push @retval, qq(<a href="$uri?$full">$_</a>\n), "<br />";
         }
         push @retval, "</p>\n";
     }
@@ -385,11 +366,11 @@
 }
 
 sub status_data_dump {
-    my($r) = @_;
+    my ($r) = @_;
 
     return install_hint('Data::Dumper') unless has($r, "dumper");
 
-    my($name, $type) = (split "/", $r->uri)[-2,-1];
+    my ($name, $type) = (split "/", $r->uri)[-2,-1];
 
     no strict 'refs';
     my @retval = "<p>\nData Dump of $name $type\n</p>\n<pre>\n";
@@ -409,11 +390,11 @@
 }
 
 sub status_cv_dump { 
-    my($r) = @_;
+    my ($r) = @_;
     return [] unless has($r, "b");
 
     no strict 'refs';
-    my($name, $type) = (split "/", $r->uri)[-2,-1];
+    my ($name, $type) = (split "/", $r->uri)[-2,-1];
     # could be another child, which doesn't have this symbol table?
     return unless *$name{CODE}; 
 
@@ -434,8 +415,8 @@
     push @retval, "Prototype: ", $proto || "none", "\n";
     push @retval, "XSUB: ",      $obj->XSUB ? "yes" : "no", "\n";
     push @retval, peek_link($r, $name, $type);
-    #push @retval, xref_link($r, $name);
     push @retval, b_graph_link($r, $name);
+    push @retval, xref_link($r, $name);
     push @retval, b_lexinfo_link($r, $name);
     push @retval, b_terse_link($r, $name);
     push @retval, b_terse_size_link($r, $name);
@@ -446,7 +427,7 @@
 }
 
 sub b_lexinfo_link {
-    my($r, $name) = @_;
+    my ($r, $name) = @_;
 
     return unless has($r, "lexinfo");
 
@@ -461,23 +442,23 @@
     return unless has($r, "lexinfo");
 
     no strict 'refs';
-    my($name) = (split "/", $r->uri)[-1];
+    my ($name) = (split "/", $r->uri)[-1];
     $r->print("Lexical Info for $name\n\n");
     my $lexi = B::LexInfo->new;
     my $info = $lexi->cvlexinfo($name);
     $r->print(${ $lexi->dumper($info) });
 }
 
-my %b_terse_exp = ('slow' => 'syntax', 'exec' => 'execution');
+my %b_terse_exp = ('slow' => 'syntax', 'exec' => 'execution', basic => 'syntax');
 
 sub b_terse_link {
-    my($r, $name) = @_;
+    my ($r, $name) = @_;
 
     return unless has($r, "terse");
 
     my $script = $r->location;
     my @retval;
-    for (qw(exec slow)) {
+    for (qw(exec basic)) {
         my $exp = "$b_terse_exp{$_} order";
         push @retval,
             qq(\n<a href="$script/$_/$name?noh_b_terse">Syntax Tree Dump ($exp)</a>\n);
@@ -492,20 +473,21 @@
     return unless has($r, "terse");
 
     no strict 'refs';
-    my($arg, $name) = (split "/", $r->uri)[-2,-1];
+    my ($arg, $name) = (split "/", $r->uri)[-2,-1];
     $r->print("Syntax Tree Dump ($b_terse_exp{$arg}) for $name\n\n");
 
     # XXX: blead perl dumps things to STDERR, though the same version
     # works fine with 1.27
     # B::Concise couldn't parse XS code before perl patch 24681 (perl 5.9.3)
-    eval { B::Terse::compile($arg, $name)->() };
+    # B::Terse is deprecated and just a wrapper around B::Concise now adays
+    eval { B::Concise::compile("-terse", "-$arg", $name)->() };
     if ($@) {
-        $r->print("B::Terse has failed: $@");
+        $r->print("B::Concise has failed: $@");
     }
 }
 
 sub b_terse_size_link {
-    my($r, $name) = @_;
+    my ($r, $name) = @_;
 
     return unless has($r, "tersesize");
 
@@ -526,7 +508,7 @@
     return unless has($r, "tersesize");
 
     $r->print('<pre>');
-    my($arg, $name) = (split "/", $r->uri)[-2,-1];
+    my ($arg, $name) = (split "/", $r->uri)[-2,-1];
     my $uri = $r->location;
     my $link = qq{<a href="$uri/$name/CODE?cv_dump">$name</a>};
     $r->print("Syntax Tree Size ($b_terse_exp{$arg} order) for $link\n\n");
@@ -534,7 +516,7 @@
 }
 
 sub b_package_size_link {
-    my($r, $name) = @_;
+    my ($r, $name) = @_;
 
     return unless has($r, "packagesize");
 
@@ -543,7 +525,7 @@
 }
 
 sub noh_b_package_size {
-    my($r) = @_;
+    my ($r) = @_;
 
     $r->content_type("text/html");
     return unless has($r, "packagesize");
@@ -551,11 +533,13 @@
     $r->print('<pre>');
 
     no strict 'refs';
-    my($package) = (split "/", $r->uri)[-1];
+    my ($package) = (split "/", $r->uri)[-1];
     my $script = $r->location;
     $r->print("Memory Usage for package $package\n\n");
-    my($subs, $opcount, $opsize) = B::TerseSize::package_size($package);
-    $r->print("Totals: $opsize bytes | $opcount OPs\n\n");
+    my ($subs, $opcount, $opsize) = B::TerseSize::package_size($package);
+    my $Kb = sprintf "%.2f", $opsize / 1024;
+    my $Mb = sprintf "%.2f", $Kb / 1000;
+    $r->print("Totals: $opsize bytes, $Kb Kb, $Mb Mb | $opcount OPs\n\n");
 
     my $nlen = 0;
     my @keys = map {
@@ -586,7 +570,7 @@
 }
 
 sub b_deparse_link {
-    my($r, $name) = @_;
+    my ($r, $name) = @_;
 
     return unless has($r, "deparse");
 
@@ -609,7 +593,7 @@
 }
 
 sub b_fathom_link {
-    my($r, $name) = @_;
+    my ($r, $name) = @_;
 
     return unless has($r, "fathom");
 
@@ -631,7 +615,7 @@
 }
 
 sub peek_link {
-    my($r, $name, $type) = @_;
+    my ($r, $name, $type) = @_;
 
     return unless has($r, "peek");
 
@@ -646,14 +630,14 @@
     return unless has($r, "peek");
 
     no strict 'refs';
-    my($name, $type) = (split "/", $r->uri)[-2,-1];
+    my ($name, $type) = (split "/", $r->uri)[-2,-1];
     $type =~ s/^FUNCTION$/CODE/;
     $r->print("Peek Dump of $name $type\n\n");
-    Apache2::Peek::Dump(*{$name}{$type});
+    Apache::Peek::Dump(*{$name}{$type});
 }
 
 sub xref_link {
-    my($r, $name) = @_;
+    my ($r, $name) = @_;
 
     return unless has($r, "xref");
 
@@ -680,7 +664,7 @@
 }
 
 sub b_graph_link {
-    my($r, $name) = @_;
+    my ($r, $name) = @_;
 
     return unless has($r, "graph");
 
@@ -706,9 +690,15 @@
     my $file = "$dir/$thing.$$.gif";
 
     unless (-e $file) {
-        tie *STDOUT, "B::Graph", $r, $file;
-        B::Graph::compile("-$type", $thing)->();
-        (tied *STDOUT)->{graph}->close;
+        my $rv = tie *STDOUT, "B::Graph", $r, $file;
+        unless ($rv) {
+            $r->content_type("text/plain");
+            $r->print("dot not found\n");
+        }
+        else {
+            B::Graph::compile("-$type", $thing)->();
+            (tied *STDOUT)->{graph}->close;
+        }
     }
 
     if (-s $file) {
@@ -730,7 +720,7 @@
 }
 
 sub B::Graph::TIEHANDLE {
-    my($class, $r, $file) = @_;
+    my ($class, $r, $file) = @_;
 
     if ($file =~ /^([^<>|;]+)$/) {
         $file = $1;
@@ -744,13 +734,17 @@
 
     require IO::File;
     my $pipe = IO::File->new("|$dot -Tgif -o $file");
-    $pipe or die "can't open pipe to dot $!";
-    $pipe->autoflush(1);
+    $pipe && $pipe->autoflush(1);
 
-    return bless {
-                  graph => $pipe,
-                  r     => $r,
-    }, $class;
+    if ($pipe) {
+        return bless {
+            graph => $pipe,
+            r     => $r,
+        }, $class;
+    }
+    else {
+        return;
+    }
 }
 
 sub B::Graph::PRINT {
@@ -762,7 +756,7 @@
 my %can_dump = map {$_,1} qw(scalars arrays hashes);
 
 sub as_HTML {
-    my($self, $package, $r) = @_;
+    my ($self, $package, $r) = @_;
 
     my @m = qw(<table>);
     my $uri = $r->uri;

Modified: perl/modperl/branches/clone-skip-unstable/lib/Apache2/compat.pm
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/lib/Apache2/compat.pm?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/lib/Apache2/compat.pm (original)
+++ perl/modperl/branches/clone-skip-unstable/lib/Apache2/compat.pm Fri Sep  2 12:25:12 2005
@@ -85,7 +85,7 @@
     require APR::Finfo;
     my $orig_sub = *Apache2::RequestRec::filename{CODE};
     *Apache2::RequestRec::filename = sub {
-        my($r, $newfile) = @_;
+        my ($r, $newfile) = @_;
         my $old_filename;
         if (defined $newfile) {
             $old_filename = $r->$orig_sub($newfile);
@@ -153,7 +153,7 @@
         my $c = shift;
         if (@_) {
             my $addr_in = shift;
-            my($port, $addr) = Socket::unpack_sockaddr_in($addr_in);
+            my ($port, $addr) = Socket::unpack_sockaddr_in($addr_in);
             $c->$orig_sub->ip_set($addr);
             $c->$orig_sub->port_set($port);
         }
@@ -195,7 +195,7 @@
     require APR::URI;
     my $orig_sub = *APR::URI::unparse{CODE};
     *APR::URI::unparse = sub {
-        my($uri, $flags) = @_;
+        my ($uri, $flags) = @_;
 
         if (defined $uri->hostname && !defined $uri->scheme) {
             # we do this only for back compat, the new APR::URI is
@@ -321,7 +321,7 @@
 package Apache;
 
 sub unescape_url_info {
-    my($class, $string) = @_;
+    my ($class, $string) = @_;
     Apache2::URI::unescape_url($string);
     $string =~ tr/+/ /;
     $string;
@@ -481,8 +481,8 @@
 *request = \&Apache2::request;
 
 sub table_get_set {
-    my($r, $table) = (shift, shift);
-    my($key, $value) = @_;
+    my ($r, $table) = (shift, shift);
+    my ($key, $value) = @_;
 
     if (1 == @_) {
         return wantarray() 
@@ -539,13 +539,13 @@
 *post_connection = \&register_cleanup;
 
 sub get_remote_host {
-    my($r, $type) = @_;
+    my ($r, $type) = @_;
     $type = Apache2::Const::REMOTE_NAME unless defined $type;
     $r->connection->get_remote_host($type, $r->per_dir_config);
 }
 
 sub parse_args {
-    my($r, $string) = @_;
+    my ($r, $string) = @_;
     return () unless defined $string and $string;
 
     return map {
@@ -599,7 +599,7 @@
 }
 
 sub clear_rgy_endav {
-    my($r, $script_name) = @_;
+    my ($r, $script_name) = @_;
     require ModPerl::Global;
     my $package = 'Apache2::ROOT' . $script_name;
     ModPerl::Global::special_list_clear(END => $package);
@@ -646,7 +646,7 @@
 #2.0 ap_send_fd() also has an additional offset parameter
 
 sub send_fd_length {
-    my($r, $fh, $length) = @_;
+    my ($r, $fh, $length) = @_;
 
     my $buff;
     my $total_bytes_sent = 0;
@@ -671,7 +671,7 @@
 }
 
 sub send_fd {
-    my($r, $fh) = @_;
+    my ($r, $fh) = @_;
     $r->send_fd_length($fh, -1);
 }
 
@@ -687,7 +687,7 @@
 use Carp ();
 
 sub new {
-    my($class) = shift;
+    my ($class) = shift;
     my $fh = Symbol::gensym;
     my $self = bless $fh, ref($class)||$class;
     if (@_) {
@@ -699,7 +699,7 @@
 }
 
 sub open {
-    my($self) = shift;
+    my ($self) = shift;
 
     Carp::croak("no Apache2::File object passed")
           unless $self && ref($self);
@@ -716,7 +716,7 @@
 }
 
 sub close {
-    my($self) = shift;
+    my ($self) = shift;
     CORE::close $self;
 }
 
@@ -761,7 +761,7 @@
 package Apache::Util;
 
 sub size_string {
-    my($size) = @_;
+    my ($size) = @_;
 
     if (!$size) {
         $size = "   0k";
@@ -818,7 +818,7 @@
 *validate_password = \&APR::Util::password_validate;
 
 sub Apache2::URI::parse {
-    my($class, $r, $uri) = @_;
+    my ($class, $r, $uri) = @_;
 
     $uri ||= $r->construct_url;
 
@@ -828,7 +828,7 @@
 package Apache::Table;
 
 sub new {
-    my($class, $r, $nelts) = @_;
+    my ($class, $r, $nelts) = @_;
     $nelts ||= 10;
     APR::Table::make($r->pool, $nelts);
 }

Modified: perl/modperl/branches/clone-skip-unstable/lib/Apache2/porting.pm
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/lib/Apache2/porting.pm?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/lib/Apache2/porting.pm (original)
+++ perl/modperl/branches/clone-skip-unstable/lib/Apache2/porting.pm Fri Sep  2 12:25:12 2005
@@ -38,7 +38,8 @@
 # XXX: unfortunately it doesn't seem to be possible to install
 # *UNIVERSAL::AUTOLOAD at the server startup, httpd segfaults,
 # child_init seems to be the first stage where it works.
-Apache2->server->push_handlers(PerlChildInitHandler => \&porting_autoload);
+Apache2::ServerUtil->server->push_handlers(
+    PerlChildInitHandler => \&porting_autoload);
 
 sub porting_autoload {
     *UNIVERSAL::AUTOLOAD = sub {

Modified: perl/modperl/branches/clone-skip-unstable/lib/ModPerl/BuildMM.pm
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/lib/ModPerl/BuildMM.pm?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/lib/ModPerl/BuildMM.pm (original)
+++ perl/modperl/branches/clone-skip-unstable/lib/ModPerl/BuildMM.pm Fri Sep  2 12:25:12 2005
@@ -26,6 +26,7 @@
 use Apache2::Build ();
 use ModPerl::MM;
 use constant WIN32 => Apache2::Build::WIN32;
+use constant CYGWIN => Apache2::Build::CYGWIN;
 
 our %PM; #add files to installation
 
@@ -91,14 +92,16 @@
         # usual. This is done for APR in xs/APR/APR/Makefile.PL.
         my $name = $args{NAME};
         if ($name =~ /^APR::\w+$/) {
-            @libs = ($build->apache_libs, $build->mp_apr_lib);
+            # For cygwin compatibility, the order of the libs should be
+            # <mod_perl libs> <apache libs>
+            @libs = ($build->mp_apr_lib, $build->apache_libs);
         }
         else {
-            @libs = ($build->apache_libs, $build->modperl_libs);
+            @libs = ($build->modperl_libs, $build->apache_libs);
         }
     }
     else {
-        @libs = ($build->apache_libs, $build->modperl_libs);
+        @libs = ($build->modperl_libs, $build->apache_libs);
     }
     $libs = join ' ', @libs;
 
@@ -150,7 +153,7 @@
         #skip .xs -> .so if we are linking static
         my $name = $self->{NAME};
         unless ($always_dynamic{$name}) {
-            if (my($xs) = keys %{ $self->{XS} }) {
+            if (my ($xs) = keys %{ $self->{XS} }) {
                 $self->{HAS_LINK_CODE} = 0;
                 print "$name will be linked static\n";
                 #propagate static xs module to src/modules/perl/Makefile
@@ -233,7 +236,7 @@
             }
         }
 
-        while (my($pm, $blib) = each %pms) {
+        while (my ($pm, $blib) = each %pms) {
             $pm   =~ s|/\./|/|g; # clean the path
             $blib =~ s|/\./|/|g; # clean the path
             my @segm = splitdir $blib;
@@ -250,7 +253,8 @@
                     "-e ModPerl::BuildMM::glue_pod $pm $podpath $blib";
 
                 # Win32 doesn't normally install man pages
-                next if WIN32;
+                # and Cygwin doesn't allow '::' in file names
+                next if WIN32 || CYGWIN;
 
                 # manify while we're at it
                 my (undef, $man, undef) = $blib =~ m!(blib/lib/)(.*)(\.pm)!;
@@ -282,7 +286,7 @@
 sub glue_pod {
 
     die "expecting 3 arguments: pm, pod, dst" unless @ARGV == 3;
-    my($pm, $pod, $dst) = @ARGV;
+    my ($pm, $pod, $dst) = @ARGV;
 
     # it's possible that the .pm file is not existing
     # (e.g. ThreadMutex.pm is not created on unless
@@ -313,7 +317,7 @@
     $build ||= build_config();
     my $pm = $self->{PM};
 
-    while (my($k, $v) = each %PM) {
+    while (my ($k, $v) = each %PM) {
         if (-e $k) {
             $pm->{$k} = $v;
         }
@@ -331,7 +335,7 @@
 my $apr_config;
 
 sub ModPerl::BuildMM::MY::libscan {
-    my($self, $path) = @_;
+    my ($self, $path) = @_;
 
     $apr_config ||= $build->get_apr_config();
 

Modified: perl/modperl/branches/clone-skip-unstable/lib/ModPerl/BuildOptions.pm
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/lib/ModPerl/BuildOptions.pm?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/lib/ModPerl/BuildOptions.pm (original)
+++ perl/modperl/branches/clone-skip-unstable/lib/ModPerl/BuildOptions.pm Fri Sep  2 12:25:12 2005
@@ -27,7 +27,7 @@
 use File::Spec;
 
 sub init {
-    my($self, $build) = @_;
+    my ($self, $build) = @_;
 
     #@ARGV should override what's in .makepl_args.mod_perl2
     #but @ARGV might also override the default MP_OPTS_FILE
@@ -68,7 +68,7 @@
 }
 
 sub parse {
-    my($self, $lines, $opts) = @_;
+    my ($self, $lines, $opts) = @_;
 
     $opts = VERBOSE|UNKNOWN_FATAL unless defined $opts;
     my $table = table();
@@ -100,7 +100,7 @@
         }
 
         if (/^MP_/) {
-            my($key, $val) = split $param_qr, $_, 2;
+            my ($key, $val) = split $param_qr, $_, 2;
             $val ||= "" unless defined $val && $val eq '0';
             $continue = $val =~ s/\\$// ? $key : "";
 
@@ -185,7 +185,7 @@
 }
 
 sub parse_table {
-    my($fh) = @_;
+    my ($fh) = @_;
     my %table;
     local $_;
 
@@ -194,7 +194,7 @@
         s/^\s+//; s/\s+$//;
         next if /^\#/ || /^$/;
         last if /^__END__/;
-        my($key, $append, $val) = split /\s+/, $_, 3;
+        my ($key, $append, $val) = split /\s+/, $_, 3;
         $table{'MP_' . $key} = { append => $append, val => $val };
     }
 

Modified: perl/modperl/branches/clone-skip-unstable/lib/ModPerl/CScan.pm
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/lib/ModPerl/CScan.pm?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/lib/ModPerl/CScan.pm (original)
+++ perl/modperl/branches/clone-skip-unstable/lib/ModPerl/CScan.pm Fri Sep  2 12:25:12 2005
@@ -398,7 +398,7 @@
 }
 
 sub typedef_structs {
-  my($typehash, $structs) = @_;
+  my ($typehash, $structs) = @_;
   my %structs;
   for (0 .. $#$structs) {
     my $in = $structs->[$_];
@@ -411,7 +411,7 @@
     my $name = parse_struct($in, \%structs);
     $structs{$key} = defined($name) ? $structs{$name} : undef;
   }
-  while (my($key, $text) = each %$typehash) {
+  while (my ($key, $text) = each %$typehash) {
     my $name = parse_struct($text->[0], \%structs);
     $structs{$key} = defined($name) ? $structs{$name} : undef;
   }
@@ -419,8 +419,8 @@
 }
 
 sub parse_struct {
-  my($in, $structs) = @_;
-  my($b, $e, $chunk, $vars, $struct, $structname);
+  my ($in, $structs) = @_;
+  my ($b, $e, $chunk, $vars, $struct, $structname);
   return "$1 $2" if $in =~ /
     ^ \s* (struct | union) \s+ (\w+) \s* $
   /x;
@@ -453,7 +453,7 @@
 
 sub parse_vars {
   my $in = shift;
-  my($vars, $type, $word, $id, $post, $func);
+  my ($vars, $type, $word, $id, $post, $func);
 
   while ($in =~ /\G\s*([\[;,(]|\*+|:\s*\d+|\S+?\b|$)\s*/gc) {
     $word = $1;
@@ -514,7 +514,7 @@
 }
 
 sub vdecl_hash {
-  my($vdecls, $mdecls) = @_;
+  my ($vdecls, $mdecls) = @_;
   my %vdecl_hash;
   for (@$vdecls, @$mdecls) {
     next if /[()]/;	# ignore functions, and function pointers
@@ -556,7 +556,7 @@
       $b1 = length $chunk, last unless defined $b1;
     }
     if ($e - $b - $b1 > 0) {
-      my($isvar, $isfunc) = (1, 1);
+      my ($isvar, $isfunc) = (1, 1);
       substr ($chunk, 0, $b1) = '';
       if ($chunk =~ /,/) {	# Contains multiple declarations.
 	push @mdecls, $b + $b1, $e;
@@ -940,7 +940,7 @@
     my $addincludes = "";
     $addincludes = "-I" . join(" -I", @$Includes)
       if defined $Includes and @$Includes;
-    my($sym) = gensym;
+    my ($sym) = gensym;
     my $cmd = WIN32 ?
         "$Cpp->{cppstdin} $Defines $addincludes $Cpp->{cppflags} $filename |" :
         "echo '\#include \"$filename\"' | $Cpp->{cppstdin} $Defines $addincludes $Cpp->{cppflags} $Cpp->{cppminus} |";

Modified: perl/modperl/branches/clone-skip-unstable/lib/ModPerl/Code.pm
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/lib/ModPerl/Code.pm?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/lib/ModPerl/Code.pm (original)
+++ perl/modperl/branches/clone-skip-unstable/lib/ModPerl/Code.pm Fri Sep  2 12:25:12 2005
@@ -125,7 +125,7 @@
     }
 }
 
-while (my($k,$v) = each %directive_proto) {
+while (my ($k,$v) = each %directive_proto) {
     $directive_proto{$k}->{ret} = 'const char *';
     my $handlers = join '_', 'handlers', canon_lc($k);
     $directive_proto{$k}->{handlers} =
@@ -168,9 +168,9 @@
 sub path { shift->{path} }
 
 sub handler_desc {
-    my($self, $h_add, $c_add) = @_;
+    my ($self, $h_add, $c_add) = @_;
     local $" = ",\n";
-    while (my($class, $h) = each %{ $self->{handler_index_desc} }) {
+    while (my ($class, $h) = each %{ $self->{handler_index_desc} }) {
         my $func = canon_func('handler', 'desc', $class);
         my $array = join '_', 'MP', $func;
         my $proto = "const char *$func(int idx)";
@@ -192,11 +192,11 @@
 }
 
 sub generate_handler_index {
-    my($self, $h_fh) = @_;
+    my ($self, $h_fh) = @_;
 
     my $type = 1;
 
-    while (my($class, $handlers) = each %{ $self->{handlers} }) {
+    while (my ($class, $handlers) = each %{ $self->{handlers} }) {
         my $i = 0;
         my $n = @$handlers;
         my $handler_type = canon_define('HANDLER_TYPE', $class);
@@ -220,11 +220,11 @@
 }
 
 sub generate_handler_hooks {
-    my($self, $h_fh, $c_fh) = @_;
+    my ($self, $h_fh, $c_fh) = @_;
 
     my @register_hooks;
 
-    while (my($class, $prototype) = each %{ $self->{hook_proto} }) {
+    while (my ($class, $prototype) = each %{ $self->{hook_proto} }) {
         my $callback = canon_func('callback', $class);
         my $return = $prototype->{ret} eq 'void' ? '' : 'return';
         my $i = -1;
@@ -243,7 +243,7 @@
                   "    ap_hook_$hook($name, NULL, NULL, $order);";
             }
 
-            my($protostr, $pass) = canon_proto($prototype, $name);
+            my ($protostr, $pass) = canon_proto($prototype, $name);
             my $ix = $self->{handler_index}->{$class}->[$i];
 
             if ($callback =~ m/modperl_callback_per_(dir|srv)/) {
@@ -275,10 +275,10 @@
 }
 
 sub generate_handler_find {
-    my($self, $h_fh, $c_fh) = @_;
+    my ($self, $h_fh, $c_fh) = @_;
 
     my $proto = 'int modperl_handler_lookup(const char *name, int *type)';
-    my(%ix, %switch);
+    my (%ix, %switch);
 
     print $h_fh "$proto;\n";
 
@@ -292,7 +292,7 @@
     switch (*name) {
 EOF
 
-    while (my($class, $handlers) = each %{ $self->{handlers} }) {
+    while (my ($class, $handlers) = each %{ $self->{handlers} }) {
         my $i = 0;
 
         for my $name (@$handlers) {
@@ -334,11 +334,11 @@
 }
 
 sub generate_handler_directives {
-    my($self, $h_fh, $c_fh) = @_;
+    my ($self, $h_fh, $c_fh) = @_;
 
     my @cmd_entries;
 
-    while (my($class, $handlers) = each %{ $self->{handlers} }) {
+    while (my ($class, $handlers) = each %{ $self->{handlers} }) {
         my $prototype = $self->{directive_proto}->{$class};
         my $i = 0;
 
@@ -391,7 +391,7 @@
 }
 
 sub generate_flags {
-    my($self, $h_fh, $c_fh) = @_;
+    my ($self, $h_fh, $c_fh) = @_;
 
     my $n = 1;
 
@@ -399,7 +399,7 @@
 
     print $h_fh "\n#define MP_SYS_$dlsrc 1\n";
 
-    while (my($class, $opts) = each %{ $self->{flags} }) {
+    while (my ($class, $opts) = each %{ $self->{flags} }) {
         my @lookup = ();
         my %lookup = ();
         my $lookup_proto = "";
@@ -499,7 +499,7 @@
 );
 
 sub generate_trace {
-    my($self, $h_fh) = @_;
+    my ($self, $h_fh) = @_;
 
     my $v     = $self->{build}->{VERSION};
     my $api_v = $self->{build}->{API_VERSION};
@@ -560,7 +560,7 @@
 }
 
 sub generate_largefiles {
-    my($self, $h_fh) = @_;
+    my ($self, $h_fh) = @_;
 
     my $flags = $self->perl_config('ccflags_uselargefiles');
 
@@ -568,7 +568,7 @@
 
     for my $flag (split /\s+/, $flags) {
         next if $flag =~ /^-/; # skip -foo flags
-        my($name, $val) = split '=', $flag;
+        my ($name, $val) = split '=', $flag;
         $val ||= '';
         $name =~ s/^-D//;
         print $h_fh "#define $name $val\n";
@@ -619,8 +619,8 @@
 }
 
 sub canon_proto {
-    my($prototype, $name) = @_;
-    my($in,$pass) = canon_args($prototype);
+    my ($prototype, $name) = @_;
+    my ($in,$pass) = canon_args($prototype);
 
     local $" = ', ';
 
@@ -710,12 +710,12 @@
 }
 
 sub init_file {
-    my($self, $name) = @_;
+    my ($self, $name) = @_;
 
     return unless $name;
     return if $self->{init_files}->{$name}++;
 
-    my(@preamble);
+    my (@preamble);
     if ($name =~ /\.h$/) {
         (my $d = uc $name) =~ s/\./_/;
         push @preamble, "#ifndef $d\n#define $d\n";
@@ -735,7 +735,7 @@
 }
 
 sub fh {
-    my($self, $name) = @_;
+    my ($self, $name) = @_;
     return unless $name;
     $self->{fh}->{$name};
 }
@@ -749,7 +749,7 @@
 }
 
 sub generate {
-    my($self, $build) = @_;
+    my ($self, $build) = @_;
 
     $self->{build} = $build;
 
@@ -760,10 +760,10 @@
     }
 
     for my $method (reverse sort keys %sources) {
-        my($h_fh, $c_fh) = map {
+        my ($h_fh, $c_fh) = map {
             $self->fh($sources{$method}->{$_});
         } qw(h c);
-        my($h_add, $c_add) = $self->$method($h_fh, $c_fh);
+        my ($h_add, $c_add) = $self->$method($h_fh, $c_fh);
         if ($h_add) {
             print $h_fh $h_add;
         }
@@ -788,7 +788,7 @@
 my $constant_prefixes = join '|', qw{APR? MODPERL_RC};
 
 sub generate_constants {
-    my($self, $h_fh, $c_fh) = @_;
+    my ($self, $h_fh, $c_fh) = @_;
 
     require Apache2::ConstantsTable;
 
@@ -827,16 +827,16 @@
 }
 
 sub constants_lookup_code {
-    my($h_fh, $c_fh, $constants, $class) = @_;
+    my ($h_fh, $c_fh, $constants, $class) = @_;
 
-    my(%switch, %alias);
+    my (%switch, %alias);
 
     %alias = %shortcuts;
 
     my $postfix = canon_lc(lc $class);
     my $package = $class . '::';
     my $package_len = length $package;
-    my($first_let) = $class =~ /^(\w)/;
+    my ($first_let) = $class =~ /^(\w)/;
 
     my $func = canon_func(qw(constants lookup), $postfix);
     my $proto = "SV \*$func(pTHX_ const char *name)";
@@ -906,9 +906,9 @@
 }
 
 sub generate_constants_lookup {
-    my($h_fh, $c_fh) = @_;
+    my ($h_fh, $c_fh) = @_;
 
-    while (my($class, $groups) = each %$Apache2::ConstantsTable) {
+    while (my ($class, $groups) = each %$Apache2::ConstantsTable) {
         my $constants = [map { @$_ } values %$groups];
 
         constants_lookup_code($h_fh, $c_fh, $constants, $class);
@@ -916,20 +916,20 @@
 }
 
 sub generate_constants_group_lookup {
-    my($h_fh, $c_fh) = @_;
+    my ($h_fh, $c_fh) = @_;
 
-    while (my($class, $groups) = each %$Apache2::ConstantsTable) {
+    while (my ($class, $groups) = each %$Apache2::ConstantsTable) {
         constants_group_lookup_code($h_fh, $c_fh, $class, $groups);
     }
 }
 
 sub constants_group_lookup_code {
-    my($h_fh, $c_fh, $class, $groups) = @_;
+    my ($h_fh, $c_fh, $class, $groups) = @_;
     my @tags;
     my @code;
 
     $class = canon_lc(lc $class);
-    while (my($group, $constants) = each %$groups) {
+    while (my ($group, $constants) = each %$groups) {
 	push @tags, $group;
         my $name = join '_', 'MP_constants', $class, $group;
 	print $c_fh "\nstatic const char *$name [] = { \n",
@@ -974,7 +974,7 @@
 my %seen_const = ();
 # generates APR::Const and Apache2::Const manpages in ./tmp/
 sub generate_constants_pod {
-    my($self) = @_;
+    my ($self) = @_;
 
     my %data = ();
     generate_constants_group_lookup_doc(\%data);
@@ -1026,9 +1026,9 @@
 }
 
 sub generate_constants_lookup_doc {
-    my($data) = @_;
+    my ($data) = @_;
 
-    while (my($class, $groups) = each %$Apache2::ConstantsTable) {
+    while (my ($class, $groups) = each %$Apache2::ConstantsTable) {
         my $constants = [map { @$_ } values %$groups];
 
         constants_lookup_code_doc($constants, $class, $data);
@@ -1036,19 +1036,19 @@
 }
 
 sub generate_constants_group_lookup_doc {
-    my($data) = @_;
+    my ($data) = @_;
 
-    while (my($class, $groups) = each %$Apache2::ConstantsTable) {
+    while (my ($class, $groups) = each %$Apache2::ConstantsTable) {
         constants_group_lookup_code_doc($class, $groups, $data);
     }
 }
 
 sub constants_group_lookup_code_doc {
-    my($class, $groups, $data) = @_;
+    my ($class, $groups, $data) = @_;
     my @tags;
     my @code;
 
-    while (my($group, $constants) = each %$groups) {
+    while (my ($group, $constants) = each %$groups) {
         $data->{$class}{$group} = [
             map {
                 my @ifdef = constants_ifdef($_);
@@ -1061,9 +1061,9 @@
 }
 
 sub constants_lookup_code_doc {
-    my($constants, $class, $data) = @_;
+    my ($constants, $class, $data) = @_;
 
-    my(%switch, %alias);
+    my (%switch, %alias);
 
     %alias = %shortcuts;
 
@@ -1095,7 +1095,7 @@
 }
 
 sub generate_exports {
-    my($self, $c_fh) = @_;
+    my ($self, $c_fh) = @_;
     require ModPerl::WrapXS;
     ModPerl::WrapXS->generate_exports($c_fh);
 }

Modified: perl/modperl/branches/clone-skip-unstable/lib/ModPerl/FunctionMap.pm
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/lib/ModPerl/FunctionMap.pm?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/lib/ModPerl/FunctionMap.pm (original)
+++ perl/modperl/branches/clone-skip-unstable/lib/ModPerl/FunctionMap.pm Fri Sep  2 12:25:12 2005
@@ -76,7 +76,7 @@
 sub guess_prefix {
     my $entry = shift;
 
-    my($name, $class) = ($entry->{name}, $entry->{class});
+    my ($name, $class) = ($entry->{name}, $entry->{class});
     my $prefix = "";
     $name =~ s/^DEFINE_//;
     $name =~ s/^mpxs_//i;
@@ -101,7 +101,7 @@
 }
 
 sub parse {
-    my($self, $fh, $map) = @_;
+    my ($self, $fh, $map) = @_;
     my %cur;
     my $disabled = 0;
 
@@ -125,7 +125,7 @@
             next;
         }
 
-        my($name, $dispatch, $argspec, $alias) = split /\s*\|\s*/;
+        my ($name, $dispatch, $argspec, $alias) = split /\s*\|\s*/;
         my $return_type;
 
         if ($name =~ s/^([^:]+)://) {
@@ -200,7 +200,7 @@
     my $map = $self->get;
     my %prefix;
 
-    while (my($name, $ent) = each %$map) {
+    while (my ($name, $ent) = each %$map) {
         next unless $ent->{prefix};
         $prefix{ $ent->{prefix} }++;
     }

Modified: perl/modperl/branches/clone-skip-unstable/lib/ModPerl/MM.pm
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/lib/ModPerl/MM.pm?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/lib/ModPerl/MM.pm (original)
+++ perl/modperl/branches/clone-skip-unstable/lib/ModPerl/MM.pm Fri Sep  2 12:25:12 2005
@@ -54,17 +54,17 @@
 }
 
 sub add_dep {
-    my($string, $targ, $add) = @_;
+    my ($string, $targ, $add) = @_;
     $$string =~ s/($targ\s+::)/$1 $add/;
 }
 
 sub add_dep_before {
-    my($string, $targ, $before_targ, $add) = @_;
+    my ($string, $targ, $before_targ, $add) = @_;
     $$string =~ s/($targ\s+::.*?) ($before_targ)/$1 $add $2/;
 }
 
 sub add_dep_after {
-    my($string, $targ, $after_targ, $add) = @_;
+    my ($string, $targ, $after_targ, $add) = @_;
     $$string =~ s/($targ\s+::.*?$after_targ)/$1 $add/;
 }
 
@@ -160,7 +160,7 @@
     my $build = build_config();
     my $pm = $self->{PM};
 
-    while (my($k, $v) = each %PM) {
+    while (my ($k, $v) = each %PM) {
         if (-e $k) {
             $pm->{$k} = $v;
         }

Modified: perl/modperl/branches/clone-skip-unstable/lib/ModPerl/Manifest.pm
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/lib/ModPerl/Manifest.pm?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/lib/ModPerl/Manifest.pm (original)
+++ perl/modperl/branches/clone-skip-unstable/lib/ModPerl/Manifest.pm Fri Sep  2 12:25:12 2005
@@ -99,7 +99,7 @@
     }
 
     my $sub = "\$matches = "
-        . "sub { my(\$arg)=\@_; return 1 if "
+        . "sub { my (\$arg)=\@_; return 1 if "
         . join (" || ",  (map {s!/!\\/!g; "\$arg =~ m/$_/o"} @skip), 0)
         . " }";
 

Modified: perl/modperl/branches/clone-skip-unstable/lib/ModPerl/MapUtil.pm
URL: http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/lib/ModPerl/MapUtil.pm?rev=267280&r1=267279&r2=267280&view=diff
==============================================================================
--- perl/modperl/branches/clone-skip-unstable/lib/ModPerl/MapUtil.pm (original)
+++ perl/modperl/branches/clone-skip-unstable/lib/ModPerl/MapUtil.pm Fri Sep  2 12:25:12 2005
@@ -114,9 +114,9 @@
     my $self = shift;
     my $package = ref($self) || $self;
 
-    my($wanted) = $package =~ /($map_classes)/io;
+    my ($wanted) = $package =~ /($map_classes)/io;
 
-    my(@dirs) = (($MapDir || './xs'), ModPerl::MapUtil::xs_glue_dirs());
+    my (@dirs) = (($MapDir || './xs'), ModPerl::MapUtil::xs_glue_dirs());
 
     my @files;
 
@@ -143,11 +143,11 @@
 }
 
 sub parse_keywords {
-    my($self, $line) = @_;
+    my ($self, $line) = @_;
     my %words;
 
     for my $pair (split /\s+/, $line) {
-        my($key, $val) = split /=/, $pair;
+        my ($key, $val) = split /=/, $pair;
 
         unless ($key and $val) {
             die "parse error ($ModPerl::MapUtil::MapFile line $.)";
@@ -160,7 +160,7 @@
 }
 
 sub parse_map_files {
-    my($self) = @_;
+    my ($self) = @_;
 
     my $map = {};
 



Mime
View raw message