Re: announce: mod_perl-1.25_01

2001-07-07 Thread Stas Bekman

On Fri, 6 Jul 2001, Doug MacEachern wrote:

 this is a 1.26 canidate, test reports most appreciated as always..

 - Linux 2.2.19-4.1mdk i686 unknown.
 - perl 5.6.1
 - apache 1.20
 - mod_perl 1.25_01
 - perl Makefile.PL APACHE_SRC=../apache_1.3.20/src \
DO_HTTPD=1 USE_APACI=1 EVERYTHING=1 \
APACHE_PREFIX=/home/httpd/httpd_perl \
APACI_ARGS='--prefix=/home/httpd/httpd_perl --enable-module=info \
--enable-module=rewrite --enable-module=proxy \
--without-execstrip' \
PERL_TRACE=1 PERL_DEBUG=1

all tests pass cleanly.



under bleed-perl (one week old compilation) (the rest is the same) there
are some problems: (perl build args are at the end of this post)

$ ./t/TEST -v modules/cgi
fails to start the server, whereas
$ make start_httpd
cp t/conf/mod_perl_srm.conf t/conf/srm.conf
../apache_1.3.20/src/httpd -f `pwd`/t/conf/httpd.conf -X -d `pwd`/t 
httpd listening on port 8529
will write error_log to: t/logs/error_log
letting apache warm up...\c
done

(it reports 'done' even if it's failed to start the server, because there
was another server running already on the same port. try to run 'make
start_httpd' twice in a row and you will see)

$ more t/logs/error_log
[Sat Jul  7 20:55:01 2001] [crit] (98)Address already in use: make_sock:
could not bind to port 8529

--

./t/TEST -v modules/cgi
modules/cgi.module CGI is installed
1..5
ok 1
ok 2
ok 3
ok 4 #(fileupload)
!DOCTYPE HTML PUBLIC -//IETF//DTD HTML 2.0//EN
HTMLHEAD
TITLE500 Internal Server Error/TITLE
/HEADBODY
H1Internal Server Error/H1
The server encountered an internal error or
misconfiguration and was unable to complete
your request.P
Please contact the server administrator,
 [no address given] and inform them of the time the error occurred,
and anything you might have done that may have
caused the error.P
More information about this error may be available
in the server error log.P
/BODY/HTML
FAILED test 5
Failed 1/5 tests, 80.00% okay
Failed Test   Status Wstat Total Fail  Failed  List of Failed
modules/cgi.t
51  20.00%  5
Failed 1/1 test scripts, 0.00% okay. 1/5 subtests failed, 80.00% okay.

reason:
[Sat Jul  7 20:57:02 2001] [error] (13)Permission denied: exec of
/usr/src/httpd_perl/mod_perl-1.25_01/t/net/perl/cgi.pl failed
[Sat Jul  7 20:57:02 2001] [error] [client 127.0.0.1] Premature end of
script headers: /usr/src/httpd_perl/mod_perl-1.25_01/t/net/perl/cgi.pl

but it shouldn't be a problem:

 ~stas/perl-bleed/bin/perl
/usr/src/httpd_perl/mod_perl-1.25_01/t/net/perl/cgi.pl
x-perl-script: cgi.pl
Content-Type: text/plain; charset=ISO-8859-1

---

./t/TEST -v modules/include
modules/include.1..4
ok 1
ok 3
FAILED tests 2, 4
Failed 2/4 tests, 50.00% okay
Failed Test   Status Wstat Total Fail  Failed  List of Failed
modules/include.t
42  50.00%  2, 4
Failed 1/1 test scripts, 0.00% okay. 2/4 subtests failed, 50.00% okay.

reason:
[Sat Jul  7 20:59:17 2001] [error] (13)Permission denied: exec of
/usr/src/httpd_perl/mod_perl-1.25_01/t/net/perl/cgi.pl failed
[Sat Jul  7 20:59:17 2001] [error] [client 127.0.0.1] Premature end of
script headers: /usr/src/httpd_perl/mod_perl-1.25_01/t/net/perl/cgi.pl
[Sat Jul  7 20:59:17 2001] [error] (13)Permission denied: exec of
/usr/src/httpd_perl/mod_perl-1.25_01/t/net/perl/cgi.pl failed
[Sat Jul  7 20:59:17 2001] [error] [client 127.0.0.1] Premature end of
script headers: /usr/src/httpd_perl/mod_perl-1.25_01/t/net/perl/cgi.pl

the same as for modules/cgi:

-rwxr-xr-x1 stas stas  452 Jul  7 20:42 /usr/src/http
d_perl/mod_perl-1.25_01/t/net/perl/cgi.pl*

I didn't have all the tests running since I miss some modules, will try
later


build warnings:

=== src/modules/perl
cc -g -I/home/stas/perl-bleed/lib/5.7.1/i686-linux-thread-multi/CORE
-D_REENTRANT -Wall -DDEBUGGING -fno-strict-aliasing -I/usr/local/include
-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -DMOD_PERL_VERSION=\1.25_01\
-DMOD_PERL_STRING_VERSION=\mod_perl/1.25_01\ -DPERL_TRACE=1 -I../..
-I/home/stas/perl-bleed/lib/5.7.1/i686-linux-thread-multi/CORE
-I../../os/unix -I../../include-DLINUX=22 -I/usr/include/db1
-DMOD_PERL -DUSE_PERL_SSI -D_REENTRANT -Wall -DDEBUGGING
-fno-strict-aliasing -I/usr/local/include -D_LARGEFILE_SOURCE
-D_FILE_OFFSET_BITS=64 -DUSE_HSREGEX -DNO_DL_NEEDED -D_REENTRANT -Wall
-DDEBUGGING -fno-strict-aliasing -I/usr/local/include -D_LARGEFILE_SOURCE
-D_FILE_OFFSET_BITS=64 -g -DPERL_DESTRUCT_LEVEL=2 `../../apaci` -c
mod_perl.c
mod_perl.c: In function `perl_restart':
mod_perl.c:333: warning: unused variable `my_perl'
mod_perl.c:359: warning: unused variable `my_perl'
mod_perl.c: In function `perl_handler':
mod_perl.c:853: warning: unused variable `my_perl'
mod_perl.c:879: warning: unused variable `my_perl'
mod_perl.c:826: 

mod_dev + mod_perl very nasty conflict

2001-07-07 Thread Jeremy Howard

A number of people have come across a problem where mod_dav shows the
contents of the filesystem root:

  http://dav.lyra.org/pipermail/dav-dev/2001-June/002487.html

I have also come across this problem, and narrowed it down (at least for me)
to a conflict with mod_perl.

I have no other non-core modules installed, no DSO install, and the
out-of-the-box httpd.conf. If I just install mod_dav and add the mimimal
httpd.conf lines for mod_dav, everything works perfectly:

DAVLockDB /usr/local/apache/DAVLock/DAVLock
DAVMinTimeout 600
DAVDepthInfinity On

Directory /usr/local/apache/htdocs/DAVdocs
DAV On
/Directory

Now I delete everything and untar it all again, and repeat the exact same
process but install mod_perl as well after mod_dav with:

cd ../mod_perl-1.25
perl Makefile.PL DO_HTTPD=1 EVERYTHING=1 APACHE_SRC=../apache_1.3.20
USE_APACI=1 PREP_HTTPD=1
make test
make install

cd ../apache_1.3.20
SSLBASE=../openssl-0.9.6a ./configure --prefix=/usr/local/apache \
--enable-module=most --disable-module=auth_dbm --disable-module=digest --ena
ble-module=auth_digest \
--activate-module=src/modules/perl/libperl.a \
--activate-module=src/modules/dav/libdav.a
make
make install

Now I get the problem of seeing the filesystem root when using DAV. This
problem occurs with both a cadaver 'ls' and with MS Web Folders. The
httpd.conf file is identical to when it worked fine (ie without mod_perl),
and it contains no IfModule mod_perl.c sections.

Any suggestions/workarounds/patches? Anyone using mod_perl + mod_dav
successfully? What versions?





RFC: Apache::SimpleTemplate

2001-07-07 Thread peter


hello!
yes, i have *yet another* templating mechanism for
mod_perl, and i'd like to add it to CPAN if there are
no major objections.

the rational:
Like other templating mechanisms, it allows you to
embed blocks of Perl code into text documents, such as
HTML files, and have this code executed upon HTTP
request. However, it is meant to be a slim and basic
alternative to existing packages (Apache::Embperl,
Apache::ASP, ...), without any added syntax/tags/etc,
and with only the bare necessities of functionality.

This is a single, small module with no dependencies
other than mod_perl. It is intended for someone with
basic templating needs, or for someone who wants a
bare-bones building-block to subclass and to add any
other methods to.

i'd like to use the name Apache::SimpleTemplate.
if anyone wants to see the current pod:
http://peter.nyc.ny.us/simpletemplate/pod.html

all thoughts are welcome.
thanks!


-- 

peter forty
[EMAIL PROTECTED]






Re: Apache::SimpleTemplate

2001-07-07 Thread Perrin Harkins

 yes, i have *yet another* templating mechanism for
 mod_perl, and i'd like to add it to CPAN if there are
 no major objections.

I hate to be a naysayer, but this doesn't look sufficiently different from
the other options to merit adding it to CPAN.  The trouble is, there are
already too many of these and it looks an awful lot like Apache::ePerl, or
Text::Template.  At the moment you may think there's a need for it because
it's simpler and smaller, but it will almost certainly grow over time.

If you look at the other modules and still think what you have is truly
different, please elaborate a little on why.  No one here is actually going
to stop you from posting it to CPAN, but I will try to talk you out of it if
there's no clear reason to prefer this over other tools.  I mean, just look
at the train wreck you get back from this:
http://search.cpan.org/search?mode=modulequery=template

- Perrin




Re: Apache::SimpleTemplate

2001-07-07 Thread peter


 I hate to be a naysayer, but this doesn't look sufficiently different from
 the other options to merit adding it to CPAN.

hi, thanks for your comments. i was expecting some such
naysaying, and understand your point. but, i still
disagree and think that simplicity *is* a valid
difference. i had looked at many other modules, and i
know other people who have as well but want a simpler
alternative.

most of the mod_perl/template packages out there are
not basic building blocks-- they lie in some
uncomfortable area between building blocks and full
content-management systems. i don't mean to knock them
at all, but for some people's needs these are way to
complex and bloated.

 The trouble is, there are already too many of these
 and it looks an awful lot like Apache::ePerl, or
 Text::Template.

Text::Template probably is the most similar existing
package, but it is not made for mod_perl. someone well-
versed in mod_perl could build a mod_perl wrapper of it
fairly quickly, but they or especially someone new to
mod_perl shouldn't have to. (i don't know of any such
wrapper existing in CPAN...)

if i'm not mistaken, Apache::ePerl builds a new
interpreter, which also seems like overkill for many
needs. (i'd like to try it out, but it won't compile
for lack of perl =5.003-- i'm using 5.6.1 :). i want a
perl-only implementation, that doesn't need a new c lib.

 At the moment you may think there's a need for it
 because it's simpler and smaller, but it will
 almost certainly grow over time.

i can't say that no features will ever be added, but i
think it is fair to say that it will always remain much
lighter and smaller. i will not add database access,
XML-hooks, or new syntax/tags, and it will always be a
straight perl implementation.

so, that's my elaboration. i really don't want to
create mess in CPAN and appreciate efforts to prevent
that, but imho this is a useful, non-superfluous
addition. if someone knows of something more similar,
or if there is no positive feedback, i will certainly
reconsider.

peter





Re: Apache::SimpleTemplate

2001-07-07 Thread brian moseley

On Sat, 7 Jul 2001 [EMAIL PROTECTED] wrote:

 Text::Template probably is the most similar existing
 package, but it is not made for mod_perl. someone well-
 versed in mod_perl could build a mod_perl wrapper of it
 fairly quickly, but they or especially someone new to
 mod_perl shouldn't have to. (i don't know of any such
 wrapper existing in CPAN...)

if such a wrapper did exist, would you use it? if it
doesn't, why don't you write one yourself?




RE: Apache::SimpleTemplate

2001-07-07 Thread Geoffrey Young

 

-Original Message-
From: brian moseley
To: [EMAIL PROTECTED]
Sent: 7/7/01 5:34 PM
Subject: Re: Apache::SimpleTemplate

On Sat, 7 Jul 2001 [EMAIL PROTECTED] wrote:

 Text::Template probably is the most similar existing
 package, but it is not made for mod_perl. someone well-
 versed in mod_perl could build a mod_perl wrapper of it
 fairly quickly, but they or especially someone new to
 mod_perl shouldn't have to. (i don't know of any such
 wrapper existing in CPAN...)

if such a wrapper did exist, would you use it? if it
doesn't, why don't you write one yourself?

I actually use Text::Template for all my templating (sigh), and have such a
wrapper (save just a bit of custom code).  I basically implement the HASH
version and use a PerlInitHandler to set up the substitutions using pnotes.
I can work it up into a more generic release if anyone is interested, but
using Text::Template is really incredibly simple and it's just a few lines
of code (and actually twice as long as it needs to be due to copious
debugging), so I really don't think a release is warranted.

In reality, I feel guilty every time I use it for not migrating to
TemplateToolkit or one of the other systems available.

--Geoff



Re: Apache::SimpleTemplate

2001-07-07 Thread peter


On Sat, 7 Jul 2001, brian moseley wrote:

 if such a wrapper did exist, would you use it?
 if it doesn't, why don't you write one yourself?

maybe.

i did use Text::Template in the first iteration of
this, but it was considerably faster to parse the
templates internally. (i don't remember how much
faster, but something like 25% for a dumb, do-nothing
template.) it seemed worth the savings not to wrap it.




ePerl (fragment of Re: Apache::SimpleTemplate)

2001-07-07 Thread Todd Finney

At 06:10 PM 7/7/01, Perrin Harkins wrote:
  if i'm not mistaken, Apache::ePerl builds a new
  interpreter, which also seems like overkill for many
  needs.

It's pretty easy to install, really.  However, it's not very popular 
these
days because it doesn't have all the features people end up needing.

We use ePerl for a fair number of things, and I have yet to run into 
something we needed of which it was not capable.   What are you 
thinking of?

I'm not trying to start a holy war - embperl is darn nifty, and I 
haven't used any of the other packages enough to have a solid opinion 
of them.   Right tool for the job, use what's comfortable, blah blah 
blah.

ePerl is butt-simple to install, and a snap to learn (put your perl in 
? here !).   We've been using it for ~4 years (I think), and have 
never seen a problem with it.  IIRC, according to the various 
benchmarks that bounce around periodically, it's not as fast as some of 
the other packages, but that's never been an issue for us.

Just asking.

cheers,
Todd






Re: Apache::SimpleTemplate

2001-07-07 Thread brian moseley

On 7 Jul 2001, Randal L. Schwartz wrote:

 Yes.  Writing a templating system in Perl is trivial.
 Writing a *useful* templating system in Perl is
 demonstratably hard.

unless you keep application features in a separate layer
from the templating system (eg the servlet api ;)




The latest templating system: PSP in DDJ

2001-07-07 Thread Ron Pero

Just received my issue of Dr. Dobbs Journal today, and one of the articles
is A Tiny Perl Server Pages Engine. Pretty nifty.

Read about it here:
http://www.ddj.com/articles/2001/0108/0108g/0108g.htm

Here is an excerpt:
PSP is modeled after JSP. It is neither an ASP nor a JSP port. PSP
includes many JSP-like features and, most importantly, custom tag support.
The latter gives you the ability to develop custom tag modules to
encapsulate complex server-side behaviors and business rules into simple
XML-like elements that content developers can use.
PSP shares the same basic elements with JSP...

And, in the tradition of TMTOWTDI, especially in the field of templating
systems, the author adds this:
Note that there is also an open-source project that is also called Perl
Server Pages (http://psp.sourceforge.net/). However, there is no connection
between that project and the one I present here.

Ron




Re: mod_perl on win2k: cannot load module

2001-07-07 Thread frans

I 've tried the new version
The problem is simple..
When i change the env of win32 i used, the mod_perl run.
I suggest you change the env by setting
set PATH=C:\perl\bin\
or wherever your perl interpreter located,
then start apache from MS-DOS prompt
Good luck

-
  Frans
  Electronics Engineering
  Department of Electrical Engineering
  Institut Teknologi Bandung
  Email: [EMAIL PROTECTED]
-

On Fri, 6 Jul 2001, frans wrote:

 I use Apache 1.3.9 and it's an old version of course..
 why don't you try compiling the source code provided by www.modperl.org ?
 Thank you.
 
 -
   Frans
   Electronics Engineering
   Department of Electrical Engineering
   Institut Teknologi Bandung
   Email: [EMAIL PROTECTED]
 -
 
 On Wed, 4 Jul 2001, Randy Kobes wrote:
 
  On Wed, 4 Jul 2001, frans wrote:
  
   Try download ApacheModulePerl.dll from
   www.cpan.org, choose by author, Jeffrey_Baker
   good luck
  
  Does this work for you? What Apache version are you using?
  The mod_perl dll is fairly dependent on the version of Apache
  it was compiled with, and this version on CPAN was compiled
  against a fairly old Apache.
  
  best regards,
  randy kobes
  
 




Re: The latest templating system: PSP in DDJ

2001-07-07 Thread Perrin Harkins

on 7/7/01 9:30 PM, Ron Pero at [EMAIL PROTECTED] wrote:

 Just received my issue of Dr. Dobbs Journal today, and one of the articles
 is A Tiny Perl Server Pages Engine. Pretty nifty.
 
 Read about it here:
 http://www.ddj.com/articles/2001/0108/0108g/0108g.htm
 
 Here is an excerpt:
 PSP is modeled after JSP. It is neither an ASP nor a JSP port. PSP
 includes many JSP-like features and, most importantly, custom tag support.
 The latter gives you the ability to develop custom tag modules to
 encapsulate complex server-side behaviors and business rules into simple
 XML-like elements that content developers can use.
 PSP shares the same basic elements with JSP...

Good grief!  This sounds exactly like Apache::ASP with its XMLSubs feature.
I give up.
- Perrin




RE: cvs commit: modperl Changes

2001-07-07 Thread Geoffrey Young


-Original Message-
From: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: 7/6/01 4:33 PM
Subject: cvs commit: modperl Changes

dougm   01/07/06 13:33:46

  Modified:src/modules/perl Apache.xs
   t/docs   startup.pl
   .Changes
  Log:
  add Apache::add_version_component() function

hmph... I can't get this to work at all.  I read over Doug's original email
and it's not what I am finding...

a verbose test shows that the test suite is able to set things properly,
though so something is going right somewhere, just not for me.

maybe this is dependent upon the placement of modules, PerlRequire, etc?

--Geoff