Return-Path: Delivered-To: apmail-httpd-apreq-cvs-archive@www.apache.org Received: (qmail 17891 invoked from network); 15 Feb 2005 06:32:43 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 15 Feb 2005 06:32:43 -0000 Received: (qmail 15182 invoked by uid 500); 15 Feb 2005 06:32:43 -0000 Delivered-To: apmail-httpd-apreq-cvs-archive@httpd.apache.org Received: (qmail 15160 invoked by uid 500); 15 Feb 2005 06:32:43 -0000 Mailing-List: contact apreq-cvs-help@httpd.apache.org; run by ezmlm Precedence: bulk Reply-To: apreq-dev@httpd.apache.org List-Post: List-Help: List-Unsubscribe: List-Subscribe: Delivered-To: mailing list apreq-cvs@httpd.apache.org Received: (qmail 15146 invoked by uid 99); 15 Feb 2005 06:32:42 -0000 X-ASF-Spam-Status: No, hits=-9.8 required=10.0 tests=ALL_TRUSTED,NO_REAL_NAME X-Spam-Check-By: apache.org Received: from minotaur.apache.org (HELO minotaur.apache.org) (209.237.227.194) by apache.org (qpsmtpd/0.28) with SMTP; Mon, 14 Feb 2005 22:32:42 -0800 Received: (qmail 17883 invoked by uid 65534); 15 Feb 2005 06:32:41 -0000 Message-ID: <20050215063241.17882.qmail@minotaur.apache.org> Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Mailer: svnmailer-1.0.0-dev Date: Tue, 15 Feb 2005 06:32:41 -0000 Subject: svn commit: r153903 - in httpd/apreq/branches/multi-env-unstable/glue/perl: Makefile.PL xsbuilder/APR/Request/Apache2/ xsbuilder/APR/Request/Apache2/Apache2.pm xsbuilder/APR/Request/CGI/ xsbuilder/APR/Request/CGI/CGI.pm xsbuilder/maps/apreq_functions.map To: apreq-cvs@httpd.apache.org From: joes@apache.org X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Author: joes Date: Mon Feb 14 22:32:38 2005 New Revision: 153903 URL: http://svn.apache.org/viewcvs?view=3Drev&rev=3D153903 Log: Get Apache2 and CGI constructors working. Added: httpd/apreq/branches/multi-env-unstable/glue/perl/xsbuilder/APR/Request= /Apache2/ httpd/apreq/branches/multi-env-unstable/glue/perl/xsbuilder/APR/Request= /Apache2/Apache2.pm httpd/apreq/branches/multi-env-unstable/glue/perl/xsbuilder/APR/Request= /CGI/ httpd/apreq/branches/multi-env-unstable/glue/perl/xsbuilder/APR/Request= /CGI/CGI.pm Modified: httpd/apreq/branches/multi-env-unstable/glue/perl/Makefile.PL httpd/apreq/branches/multi-env-unstable/glue/perl/xsbuilder/maps/apreq_= functions.map Modified: httpd/apreq/branches/multi-env-unstable/glue/perl/Makefile.PL URL: http://svn.apache.org/viewcvs/httpd/apreq/branches/multi-env-unstable/= glue/perl/Makefile.PL?view=3Ddiff&r1=3D153902&r2=3D153903 =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D --- httpd/apreq/branches/multi-env-unstable/glue/perl/Makefile.PL (original) +++ httpd/apreq/branches/multi-env-unstable/glue/perl/Makefile.PL Mon Feb 1= 4 22:32:38 2005 @@ -271,6 +271,21 @@ undef; } =20 +sub mod_pm { + my($self, $module, $complete) =3D @_; + my $dirname =3D $self->class_dirname($module); + my @parts =3D split '::', $module; + my $mod_pm =3D "$dirname/$parts[-1].pm"; + + for ($self -> xs_include_dir, @{ $self->{glue_dirs} }) { + my $file =3D "$_/$mod_pm"; + $mod_pm =3D $file if $complete; + return $mod_pm if -e $file; + } + + undef; +} + #inline mod_xs directly, so we can put XS directives there =20 sub write_xs { @@ -530,19 +545,24 @@ c2perl =3D> 'apreq_xs_param2sv(ptr)', }, T_APREQ_HANDLE =3D> { - INPUT =3D> '$var =3D apreq_xs_perl2c(aTHX_ $a= rg, "r")', - perl2c =3D> 'apreq_xs_perl2c(aTHX_ sv, "r")', + INPUT =3D> '$var =3D apreq_xs_perl2c(aTHX_ $a= rg, \"r\")', + perl2c =3D> 'apreq_xs_perl2c(aTHX_ sv, \"r\")', c2perl =3D> 'sv_setref_pv(newSV(0), class, ptr= )', OUTPUT =3D> <<'EOT', - $arg =3D sv_setref_pv($arg, class, $var); - if (!sv_derived_from($arg, \"${ntype}\")) + $arg =3D sv_setref_pv(newSV(0), class, $var); + if (sv_derived_from($arg, \"${ntype}\")) { + SV *parent =3D ST(1); + SV *rv =3D SvRV($arg); + sv_magic(rv, parent, PERL_MAGIC_ext, Nullch, 0); + } + else Perl_croak(aTHX_ \"Usage: target class %s isn't derived from ${nty= pe}\", class); EOT }, T_APREQ_HANDLE_APACHE2 =3D> { - INPUT =3D> '$var =3D apreq_xs_perl2c(aTHX_ $a= rg, "r")', + INPUT =3D> '$var =3D apreq_xs_perl2c(aTHX_ $a= rg, \"r\")', OUTPUT =3D> <<'EOT', - $arg =3D sv_setref_pv($arg, class, $var); + $arg =3D sv_setref_pv(newSV(0), class, $var); if (sv_derived_from($arg, \"${ntype}\")) { SV *parent =3D ST(1); /* r's SV */ SV *rv =3D SvRV($arg); Added: httpd/apreq/branches/multi-env-unstable/glue/perl/xsbuilder/APR/Requ= est/Apache2/Apache2.pm URL: http://svn.apache.org/viewcvs/httpd/apreq/branches/multi-env-unstable/= glue/perl/xsbuilder/APR/Request/Apache2/Apache2.pm?view=3Dauto&rev=3D153903 =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D --- httpd/apreq/branches/multi-env-unstable/glue/perl/xsbuilder/APR/Request= /Apache2/Apache2.pm (added) +++ httpd/apreq/branches/multi-env-unstable/glue/perl/xsbuilder/APR/Request= /Apache2/Apache2.pm Mon Feb 14 22:32:38 2005 @@ -0,0 +1,2 @@ +require APR::Request; +push @ISA, "APR::Request"; Added: httpd/apreq/branches/multi-env-unstable/glue/perl/xsbuilder/APR/Requ= est/CGI/CGI.pm URL: http://svn.apache.org/viewcvs/httpd/apreq/branches/multi-env-unstable/= glue/perl/xsbuilder/APR/Request/CGI/CGI.pm?view=3Dauto&rev=3D153903 =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D --- httpd/apreq/branches/multi-env-unstable/glue/perl/xsbuilder/APR/Request= /CGI/CGI.pm (added) +++ httpd/apreq/branches/multi-env-unstable/glue/perl/xsbuilder/APR/Request= /CGI/CGI.pm Mon Feb 14 22:32:38 2005 @@ -0,0 +1,2 @@ +require APR::Request; +push @ISA, "APR::Request"; Modified: httpd/apreq/branches/multi-env-unstable/glue/perl/xsbuilder/maps/= apreq_functions.map URL: http://svn.apache.org/viewcvs/httpd/apreq/branches/multi-env-unstable/= glue/perl/xsbuilder/maps/apreq_functions.map?view=3Ddiff&r1=3D153902&r2=3D1= 53903 =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D --- httpd/apreq/branches/multi-env-unstable/glue/perl/xsbuilder/maps/apreq_= functions.map (original) +++ httpd/apreq/branches/multi-env-unstable/glue/perl/xsbuilder/maps/apreq_= functions.map Mon Feb 14 22:32:38 2005 @@ -105,7 +105,11 @@ =20 #################### APR::Request stuff #################### =20 -MODULE=3DAPR::Request PACKAGE=3DAPR::Request +MODULE=3DAPR::Request PACKAGE=3DAPR::Request PREFIX=3Dapreq_ +apreq_jar_get +apreq_body_get +apreq_args_get + #DEFINE_jar | apreq_xs_jar | #DEFINE_args | apreq_xs_args | #DEFINE_body | apreq_xs_body |