aboutsummaryrefslogtreecommitdiff
path: root/www
diff options
context:
space:
mode:
authorSimon Barner <barner@FreeBSD.org>2005-03-11 22:23:27 +0000
committerSimon Barner <barner@FreeBSD.org>2005-03-11 22:23:27 +0000
commit6ca3c99ebabafda044bbc62dfed6ebc626f5bfce (patch)
tree68144fd74f875014a5ce4b8ac9bb2c4edd7a0628 /www
parent92fb09df2b0525d049e6579f3ee44df2f6577d69 (diff)
downloadports-6ca3c99ebabafda044bbc62dfed6ebc626f5bfce.tar.gz
ports-6ca3c99ebabafda044bbc62dfed6ebc626f5bfce.zip
Notes
Diffstat (limited to 'www')
-rw-r--r--www/Makefile1
-rw-r--r--www/p5-PLP/Makefile56
-rw-r--r--www/p5-PLP/distinfo2
-rw-r--r--www/p5-PLP/files/extra-patch-mod_perl2.pm53
-rw-r--r--www/p5-PLP/pkg-descr12
-rw-r--r--www/p5-PLP/pkg-plist12
6 files changed, 136 insertions, 0 deletions
diff --git a/www/Makefile b/www/Makefile
index b701334f39dd..39db6176c308 100644
--- a/www/Makefile
+++ b/www/Makefile
@@ -528,6 +528,7 @@
SUBDIR += p5-Maypole-Authentication-UserSessionCookie
SUBDIR += p5-Maypole-Component
SUBDIR += p5-PHP-Session
+ SUBDIR += p5-PLP
SUBDIR += p5-POE-Component-Client-HTTP
SUBDIR += p5-POE-Component-Client-UserAgent
SUBDIR += p5-POE-Component-Server-HTTP
diff --git a/www/p5-PLP/Makefile b/www/p5-PLP/Makefile
new file mode 100644
index 000000000000..573144198447
--- /dev/null
+++ b/www/p5-PLP/Makefile
@@ -0,0 +1,56 @@
+# New ports collection makefile for: PLP
+# Date created: Sun May 23 13:27:20 EDT 2004
+# Whom: Christopher Nehren <apeiron@comcast.net>
+#
+# $FreeBSD$
+#
+
+PORTNAME= PLP
+PORTVERSION= 3.18
+CATEGORIES= www perl5
+MASTER_SITES= http://plp.juerd.nl/files/
+PKGNAMEPREFIX= p5-
+
+MAINTAINER= apeiron@comcast.net
+COMMENT= A simple Perl embedder superficially resembling PHP
+
+PERL_CONFIGURE= yes
+
+MAN3= PLP.3 PLP::FAQ.3 PLP::Fields.3 PLP::Functions.3 PLP::HowTo.3 \
+ PLP::Tie::Delay.3 PLP::Tie::Headers.3 PLP::Tie::Print.3
+
+.if defined(WITH_MOD_PERL)
+.if ${WITH_MOD_PERL} == 1
+RUN_DEPENDS+= ${SITE_PERL}/${PERL_ARCH}/mod_perl.pm:${PORTSDIR}/www/mod_perl
+.elif ${WITH_MOD_PERL} == 2
+RUN_DEPENDS+= ${SITE_PERL}/${PERL_ARCH}/Apache2/mod_perl.pm:${PORTSDIR}/www/mod_perl2
+EXTRA_PATCHES= ${PATCHDIR}/extra-patch-mod_perl2.pm
+.else
+IGNORE= WITH_MOD_PERL must be either '1' or '2', or undefined
+.endif
+.endif
+
+.include <bsd.port.pre.mk>
+
+pre-fetch:
+ @${ECHO_CMD}
+.if defined(WITH_MOD_PERL)
+.if ${WITH_MOD_PERL} == 1
+ @${ECHO_CMD} "Enabling mod_perl 1.x support."
+.elif ${WITH_MOD_PERL} == 2
+ @${ECHO_CMD} "Be aware that the patch to make PLP function with mod_perl 2 is"
+ @${ECHO_CMD} "both unofficial and unsupported. It requires mod_perl 2's mod_perl 1"
+ @${ECHO_CMD} "compatibility interface. In using mod_perl 2 you are assumed to know"
+ @${ECHO_CMD} "what you are doing."
+.endif
+.else
+ @${ECHO_CMD} "This port supports either mod_perl 1 or mod_perl 2 (with an"
+ @${ECHO_CMD} "experimental patch and mod_perl 2's compat interface)."
+ @${ECHO_CMD} "mod_perl is not required for PLP to function, but you"
+ @${ECHO_CMD} "can expect a 50-200% speed increase with mod_perl support."
+ @${ECHO_CMD}
+ @${ECHO_CMD} " WITH_MOD_PERL=1 Enables mod_perl 1.x support"
+ @${ECHO_CMD} " WITH_MOD_PERL=2 Enables unofficial, experimental mod_perl 2.x support"
+.endif
+ @${ECHO_CMD}
+.include <bsd.port.post.mk>
diff --git a/www/p5-PLP/distinfo b/www/p5-PLP/distinfo
new file mode 100644
index 000000000000..e334c73e373a
--- /dev/null
+++ b/www/p5-PLP/distinfo
@@ -0,0 +1,2 @@
+MD5 (PLP-3.18.tar.gz) = 2d3ad7ecfa0f437fa4e2e0074e9af07e
+SIZE (PLP-3.18.tar.gz) = 18788
diff --git a/www/p5-PLP/files/extra-patch-mod_perl2.pm b/www/p5-PLP/files/extra-patch-mod_perl2.pm
new file mode 100644
index 000000000000..3258fa4eca4c
--- /dev/null
+++ b/www/p5-PLP/files/extra-patch-mod_perl2.pm
@@ -0,0 +1,53 @@
+--- PLP.pm.orig Fri Oct 18 15:47:07 2002
++++ PLP.pm Tue Jun 1 15:49:07 2004
+@@ -131,7 +131,12 @@
+
+ # This is the mod_perl handler.
+ sub handler {
+- require Apache::Constants;
++ if($ENV{'mod_perl2_compat'} eq 'on') {
++ use Apache::Const -compile => qw(OK);
++ }
++ else {
++ require Apache::Constants;
++ }
+ clean();
+ if (my $ret = mod_perl_init($_[0])) {
+ return $ret;
+@@ -139,7 +144,12 @@
+ #S start($_[0]);
+ start();
+ no strict 'subs';
+- return Apache::Constants::OK();
++ if($ENV{'mod_perl2_compat'} eq 'on') {
++ return Apache::Const::OK;
++ }
++ else {
++ return Apache::Constants::OK();
++ }
+ }
+
+ # mod_perl initializer: returns 0 on success, Apache error code on failure
+@@ -151,10 +161,20 @@
+ $ENV{PLP_FILENAME} = my $filename = $r->filename;
+
+ unless (-f $filename) {
+- return Apache::Constants::NOT_FOUND();
++ if($ENV{'mod_perl2_compat'} eq 'on') {
++ return Apache::Const::NOT_FOUND();
++ }
++ else {
++ return Apache::Constants::NOT_FOUND();
++ }
+ }
+ unless (-r _) {
+- return Apache::Constants::FORBIDDEN();
++ if($ENV{'mod_perl2_compat'} eq 'on') {
++ return Apache::Const::FORBIDDEN();
++ }
++ else {
++ return Apache::Constants::FORBIDDEN();
++ }
+ }
+
+ $ENV{PLP_NAME} = $r->uri;
diff --git a/www/p5-PLP/pkg-descr b/www/p5-PLP/pkg-descr
new file mode 100644
index 000000000000..b879ecbecd9c
--- /dev/null
+++ b/www/p5-PLP/pkg-descr
@@ -0,0 +1,12 @@
+PLP is yet another Perl embedder, primarily for HTML documents. Unlike with
+other Perl embedders, there is no need to learn a meta-syntax or object
+model: one can just use the normal Perl constructs. PLP runs under mod_perl
+for speeds comparable to those of PHP, but can also be run as a CGI script.
+
+Note that while unofficial, experimental, and not supported, I (PLP's
+maintainer) have been using the patch for mod_perl 2 functionality for about a
+year's time on servers which are always online. I have yet to encounter any
+problems. If you do encounter any, please send a report to me first and I'll do
+what I can to see if it's a bug in PLP or a bug in the mod_perl 2 patch.
+
+WWW: http://plp.juerd.nl/
diff --git a/www/p5-PLP/pkg-plist b/www/p5-PLP/pkg-plist
new file mode 100644
index 000000000000..e6614e947815
--- /dev/null
+++ b/www/p5-PLP/pkg-plist
@@ -0,0 +1,12 @@
+%%SITE_PERL%%/PLP.pm
+%%SITE_PERL%%/PLP/FAQ.pod
+%%SITE_PERL%%/PLP/Fields.pm
+%%SITE_PERL%%/PLP/Functions.pm
+%%SITE_PERL%%/PLP/HowTo.pod
+%%SITE_PERL%%/PLP/Tie/Delay.pm
+%%SITE_PERL%%/PLP/Tie/Headers.pm
+%%SITE_PERL%%/PLP/Tie/Print.pm
+%%SITE_PERL%%/%%PERL_ARCH%%/auto/PLP/.packlist
+@dirrm %%SITE_PERL%%/PLP/Tie
+@dirrm %%SITE_PERL%%/PLP
+@dirrm %%SITE_PERL%%/%%PERL_ARCH%%/auto/PLP