Re: Value of ErrorLog directive via mod_perl

2000-09-26 Thread Bjørn Ola Smievoll

* Doug MacEachern
|
| On 15 Sep 2000, Bjørn Ola Smievoll wrote:
| 
|  I need to retrieve the value of the ErrorLog directive (i.e. the path
|   filename of the error_log), but I can't find a way to do it with
|  mod_perl.  (The C api equivalent is the error_fname field in the
|  server_rec struct).
| 
| this patch should work.  can you tell me why you need it so i can decide
| if this should be added to the distribution?

I want to return the last 5 lines or so of the error_log each time
there's a 500 error.  The faculty and students ordinarily don't have
access to the error log, so it will be helpful for them to see the
last lines from the log file to help them fix problems with their
documents (mostly wrong file perms and stuff like that).

I could hardcode the value, but since we distribute our server package
to well over 50 servers, some running multiple virtualhosts, I doubt
that would work very well.

(From a security standpoint this might not be the best idea, so I'll
probably limit it to lines that start with [ (so not to return the
occasional perl code dump) and to our local domain as it's only useful
if you're able to fix the problem as well (useful in an
non-evil-minded context that is)).


Thanks,

(bo)



perl-5.6.0 installation with gcc

2000-09-26 Thread Dhananjay Naniwadekar

I just installed perl-5.6.0 from CPAN on hpux. But I had to use cc. It gave
me
errors when I tried to compile perl with gcc. Any idea what could be going
wrong?

I get a warning / error message : there is a BIG problem with your setup.

- nani (Dhananjay Naniwadekar)




RE: Apache::Request-new() problem

2000-09-26 Thread Geoffrey Young



 -Original Message-
 From: Herrington, Jack [mailto:[EMAIL PROTECTED]]
 Sent: Monday, September 25, 2000 10:36 PM
 To: [EMAIL PROTECTED]
 Subject: Apache::Request-new() problem
 
 
 I have the same problem as one of the previous reporters with
 Apache::Request-new().  The problem occurs whether I call it 
 after a 'use'
 or after a 'PerlModule' load.  Perl returns the no 'new' 
 method could be
 found for Apache::Request.
 
 My setup is:
 
 Apache 1.3.12
 mod_perl 1.24
 Perl 6.5
 Redhat 6.2
 libapreq 0.31
 
 Both Apache::Request and Apache::Cookie exhibit the same symptoms, and
 simply running this Perl script:
 
 use Apache::Request;
 my $apr = Apache::Request-new( $r );
 
 Gives exactly the same response (as opposed to complaining about the
 unititliazed $r).
 
 Is there anywhere I can locate the original Apache::Request 
 all-Perl code?

well, if you don't have that, then you likely don't have Apache::Request or
Apache::Cookie - they aren't part of the mod_perl distribution :)

you need libapreq, which can be found under the Apache tree on CPAN

HTH

--Geoff

 
 Jack Herrington
   Engineering Manager
   Certive - Building the world's first broadband B2B network
   (650) 701-8809
 



RE: open(FH,'|qmail-inject') fails

2000-09-26 Thread Jeff Warner

If you are using qmail-inject in a high volume configuration, make sure you
reduce or eliminate most of its logging, otherwise the system will spin its
wheels doing logging work and not sending out emails.

Haven't compared Net::SMTP to qmail-inject, but qmail-inject is
significantly faster than straight sendmail on Linux.

Jeff

-Original Message-
From: Doug MacEachern [mailto:[EMAIL PROTECTED]]
Sent: Monday, September 25, 2000 5:21 PM
To: Stas Bekman
Cc: Bill Moseley; Modperl
Subject: Re: open(FH,'|qmail-inject') fails


On Mon, 25 Sep 2000, Stas Bekman wrote:

 All you care about is to measure the time between email sending start and
 end (when the process continues on its execution flow). Why should one
 care about the details of internal implementation.

i only skimmed the first part of this thread, but assumed if you're
talking about performance, you'd want to compare the overall impact on
your system(s) of Net::SMTP vs. |qmail-inject.  you cannot measure the
overall impact just using Benchmark.pm is all i'm trying to clarify.





It just stopped work...

2000-09-26 Thread Luis 'Champs' de Carvalho


Hi, list people...
I have a serious problem here... 
I'm building a rewriting proxy for my apache with mod_perl.
(Source code here: http://www.sourceforge.net/projects/myproxy/)
Have a nice beta release... 
So i decided that it was time to refresh the perl libs.
Started the CPAN module in shell mode and asked for a 'install
Bundle::CPAN', and for a 'install LWP' followed by a 'install HTTP HTML
URI'.
All install requests completed successfully.

Since that, my perl handler just stops work with a message like
this:

=

[Tue Sep 26 10:50:07 2000] [notice] Apache/1.3.9 (Unix) Debian/GNU
mod_ssl/2.4.10 OpenSSL/0.9.4 mod_perl/1.21_03-dev configured -- resuming
normal operations

[Tue Sep 26 10:50:07 2000] [notice] suEXEC mechanism enabled
(wrapper: /usr/lib/apache/suexec)

[Tue Sep 26 10:50:43 2000] [error] Can't locate object method "schema" via
package "URI::http" at /usr/local/lib/site_perl/URI/WithBase.pm line 48.

==

Allways at the first request.

I don't know what to do!
Please, help me!!
[]'z!

 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
 Luis 'Champs' de Carvalho   @@   @@   @@
 SysAdmin at TBN @@   @@   @@
 mail to:[EMAIL PROTECTED] @@  @@
 http://www.tbn.com.br/@@  @@
 Phone: +55(011)3845.5964@@    @@
 "There's no spoon." @@    @@
 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=







RE: Apache::Request-new() problem

2000-09-26 Thread Herrington, Jack

well, if you don't have that, then you likely don't have Apache::Request or
Apache::Cookie - they aren't part of the mod_perl distribution :)
you need libapreq, which can be found under the Apache tree on CPAN

libapreq appears to come with Bundle::Apache, but I also downloaded it
seperately and installed it directly.

My thinking is that the XS code isn't working with Perl 5.6.  There are
other XS based libraries that are working (like MD5), but this one refuses
to work.




Scheduling an Apache child for termination/influence MaxRequestsPerChild counter

2000-09-26 Thread Ime Smits

Hi,

I wonder if it's possible to somehow alter Apache's internal counter matched
against MaxRequestPerChild or schedule the launching of a new child from
withing mod_perl.

The reason I want to do this, is that in the administrator section of my
website, quite some stuff gets cached from the PostgreSQL backend on a per
process basis and there is really no use to keep all those caches after the
administrator hit the logout button.

Plus, I want to be able to terminate a process if some kind cache
inconsistency is detected. I know it's better to track the origin of that
inconsistency and fix it there, but I'm using some modules which I did not
create myself and I'm not planning to dig into 5000+ lines of code I did not
wrote. What I really would like to do is to just finish the current page,
dropping a line like "things are getting fishy here", wipe the
administrator's session cookie and let the child die.

Ime




Re: Scheduling an Apache child for termination/influenceMaxRequestsPerChild counter

2000-09-26 Thread David Alan Pisoni

At 18.56 +0200 9/26/2000, Ime Smits wrote:
Hi,

I wonder if it's possible to somehow alter Apache's internal counter matched
against MaxRequestPerChild or schedule the launching of a new child from
withing mod_perl.

The reason I want to do this, is that in the administrator section of my
website, quite some stuff gets cached from the PostgreSQL backend on a per
process basis and there is really no use to keep all those caches after the
administrator hit the logout button.

Plus, I want to be able to terminate a process if some kind cache
inconsistency is detected. I know it's better to track the origin of that
inconsistency and fix it there, but I'm using some modules which I did not
create myself and I'm not planning to dig into 5000+ lines of code I did not
wrote. What I really would like to do is to just finish the current page,
dropping a line like "things are getting fishy here", wipe the
administrator's session cookie and let the child die.

Ime

Can you run the administrative section of your site in a separate server process?  
That way, you can tune your MaxClients and MaxRequestsPerChild levels very low for 
that server, while preventing your front-end server from allocating excessive chunks 
of RAM (and leaving the afformentioned settings optimized.)

Enjoy,
-- 
David Pisoni -- [EMAIL PROTECTED]
 Cnation -- http://www.cnation.com/
310/228-6900 -- 310/228-6905 (fax)

"The opposite of a correct statement is a false statement. But the opposite of
a profound truth may well be another profound truth." -Niels Bohr, physicist
(1885-1962)



RE: Apache::Request-new() problem

2000-09-26 Thread Geoffrey Young



 -Original Message-
 From: Herrington, Jack [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, September 26, 2000 12:17 PM
 To: [EMAIL PROTECTED]
 Subject: RE: Apache::Request-new() problem
 
 
 well, if you don't have that, then you likely don't have 
 Apache::Request or
 Apache::Cookie - they aren't part of the mod_perl distribution :)
 you need libapreq, which can be found under the Apache tree on CPAN
 
 libapreq appears to come with Bundle::Apache, but I also downloaded it
 seperately and installed it directly.

oh, ok...

if running from Registry, try this:
#!/usr/bin/perl
use strict;
use Apache::Request;
my $apr = Apache::Request-new(shift);

if that fails, start checking the usual suspects: 
libapreq was built, but not actually installed in perl's @INC
mod_perl wasn't built with EVERYTHING=1 (I'm not sure whether
libapreq needs PERL_TABLE_API=1 or not)

those ought to help some...

if that fails, send the exact script, OS, build options, actual error
messages, etc...

 
 My thinking is that the XS code isn't working with Perl 5.6.  

I have it working with 5.6 on linux just fine...

 There are
 other XS based libraries that are working (like MD5), but 
 this one refuses
 to work.

HTH

--Geoff 



RE: Scheduling an Apache child for termination/influence MaxRequestsPerChild counter

2000-09-26 Thread Geoffrey Young



 -Original Message-
 From: Ime Smits [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, September 26, 2000 12:57 PM
 To: [EMAIL PROTECTED]
 Subject: Scheduling an Apache child for termination/influence
 MaxRequestsPerChild counter
 
 
 Hi,
 
 I wonder if it's possible to somehow alter Apache's internal 
 counter matched
 against MaxRequestPerChild or schedule the launching of a new 
 child from
 withing mod_perl.
 
 The reason I want to do this, is that in the administrator 
 section of my
 website, quite some stuff gets cached from the PostgreSQL 
 backend on a per
 process basis and there is really no use to keep all those 
 caches after the
 administrator hit the logout button.

http://perl.apache.org/guide/porting.html#Terminating_requests_and_process

see the part on child_terminate()

HTH

--Geoff

 
 Plus, I want to be able to terminate a process if some kind cache
 inconsistency is detected. I know it's better to track the 
 origin of that
 inconsistency and fix it there, but I'm using some modules 
 which I did not
 create myself and I'm not planning to dig into 5000+ lines of 
 code I did not
 wrote. What I really would like to do is to just finish the 
 current page,
 dropping a line like "things are getting fishy here", wipe the
 administrator's session cookie and let the child die.
 
 Ime
 



Re: Can't locate object method No via package such

2000-09-26 Thread Doug MacEachern

On 25 Sep 2000, Alan E. Derhaag wrote:
 
 Good try, but /dev/null is not broken on my machine.

ok, i have seen this happen at least once in the past, glad it's not a
common problem.  looking back now at some other mod_ssl fixes for 'make
test', i'm reading that mod_ssl has some sort of problem with /dev/null.
i don't know the details, but maybe this patch will fix the problem for
you.  however, we had switched from -e0 to /dev/null in mod_perl-1.17,
something todo with suexec/setuid, which i think will still be a problem
looking at perl.c:

if (PL_euid != PL_uid || PL_egid != PL_gid)
Perl_croak(aTHX_ "No -e allowed in setuid scripts");


--- src/modules/perl/mod_perl.c 2000/09/01 05:23:17 1.126
+++ src/modules/perl/mod_perl.c 2000/09/26 17:03:39
@@ -668,7 +668,7 @@
 #ifdef WIN32
 argv[argc++] = "nul";
 #else
-argv[argc++] = "/dev/null";
+argv[argc++] = "-e0";
 #endif
 
 MP_TRACE_g(fprintf(stderr, "perl_parse args: "));





Re: Apache::Request-new() problem

2000-09-26 Thread Doug MacEachern

On Mon, 25 Sep 2000, Herrington, Jack wrote:

 I have the same problem as one of the previous reporters with
 Apache::Request-new().  The problem occurs whether I call it after a 'use'
 or after a 'PerlModule' load.  Perl returns the no 'new' method could be
 found for Apache::Request.

sounds to me like your script is not running under mod_perl.
Apache/Request.pm calls this to bootstrap the xs interface:

__PACKAGE__-mod_perl::boot($VERSION);

if you are not running under mod_perl ($ENV{MOD_PERL} is not set), then
the interface is not bootstrapped.  this is done so 'perl -c' can be run
on scripts that 'use Apache::*' with apis only available when running
inside the server.




Re: It just stopped work...

2000-09-26 Thread Doug MacEachern

On Tue, 26 Sep 2000, Luis 'Champs' de Carvalho wrote:
 
 [Tue Sep 26 10:50:43 2000] [error] Can't locate object method "schema" via
  ^
 package "URI::http" at /usr/local/lib/site_perl/URI/WithBase.pm line 48.

line 48 is an AUTOLOAD routine:
$self-[0]-$method(@_);

looks like your code is calling '$uri-schema', rather than '$uri-scheme'





Re: Value of ErrorLog directive via mod_perl

2000-09-26 Thread Doug MacEachern

On 26 Sep 2000, Bjørn Ola Smievoll wrote:
 
 I want to return the last 5 lines or so of the error_log each time
 there's a 500 error.  The faculty and students ordinarily don't have
 access to the error log, so it will be helpful for them to see the
 last lines from the log file to help them fix problems with their
 documents (mostly wrong file perms and stuff like that).
 
 I could hardcode the value, but since we distribute our server package
 to well over 50 servers, some running multiple virtualhosts, I doubt
 that would work very well.

ok, that does sound useful.  i've committed the patch to cvs.




Re: question: using Apache for non-HTML messages

2000-09-26 Thread Doug MacEachern

On Mon, 25 Sep 2000, B. Burke wrote:
 
 I've been able to basically remove the response headers by removing the
 functionality
 of ap_sen_header_field() before compiling Apache, but it would be nice to

you don't have to remove anything, just don't call $r-send_http_header
and make sure PerlSendHeader is configured to Off, then Apache will not
send any headers.




Re: Apache::DB in emacs

2000-09-26 Thread Doug MacEachern

On 24 Sep 2000 [EMAIL PROTECTED] wrote:

 Can anyone tell me if there is a way to run mod_perl's Apache::DB under
 emacs?

there are some 'remote' hooks in the Perl debugger (perl5db.pl), but i've
only heard about it, never tried, so not sure if that is a possible
solution.  i don't think Apache::DB as-is will run under emacs, unless
somebody with enough emacs-lisp-fu can rig something up to run 'httpd -X
-DPERLDB' under emacs.




Re: Solution for: Re: $ENV{PATH} set by mod_perl script affectsmod_cgi scripts

2000-09-26 Thread Doug MacEachern

On Tue, 6 Jun 2000, Ben Cohen wrote:
 
 This was certainly a weird bug ( I think it was a bug ).
 Even setting PerlSetEnv in httpd.conf didn't help.
 The PATH would be properly set until the first time a mod_perl
 script modified its PATH at which point all other 
 scripts including mod_cgi scripts would 'inherit' this
 new PATH.

you should be able to cure this simply by localizing:

local $ENV{PATH} = "/bin:/usr/local/bin";

is that not the case?




Re: subprocess_env

2000-09-26 Thread Doug MacEachern

On Thu, 8 Jun 2000, Ian Kallen wrote:

 
 I'm using a third party module that writes a bunch of variables to the
 subprocess_env table to setup data for the request. It has us making
 repeated class method calls like this (for our usage with Mason):
 % Blah::foo('bletch') %
 
 where foo is in the Blah package merely doing this:
 
 sub foo {
 my($s) = @_;
 my($r) = Apache-request();
 return $r-subprocess_env('foo_' . $s);
 }
 
 I'm thinking of changing the behvior to 
 % $ENV{'foo_bletch'} %
 but foo_bletch isn't in the %ENV hash, so I'm looking at initializing
 every request to do this:
 $r-subprocess_env-do(
  sub { my($k,$v)=@_;
$ENV{$k}=$v;
  1; 
  }
 );
 to eliminate repeated accesses of the subprocess_env table; one call
 populates %ENV and that's it.
 
 Now, I don't want to kick off a debate on the performance problems that
 reading/writing to the environment incur; I didn't design this behavior
 I just want to make the best of it since this is what the application
 requires of us. I just need to optimize access to the environment by
 turning the dozen or so calls per request to Blah::foo to just %ENV.  
 
 Any ideas regarding the expense of mulitple $r-subprocess_env vs.
 accessing %ENV?

%ENV will probably be faster for lookups, since subprocess_env has the
overhead of calling a perl subroutine (pp_entersub).  it's the population
of %ENV that can be expensive.  you might be better off populating a
non-magic global, such as %Env.




Re: dir_config and Apache::Table confusion

2000-09-26 Thread Bjørn Ola Smievoll

* Doug MacEachern
|
| works fine for me with this config:

[ ... ]
 
| with mod_perl-1.24_01-dev, apache_1.3.13-dev, perl-current (5.7.0@7093)


Works for me too when PerlSetVar is inside a Location /foo, but not
when it's defined outside, in the 'root' of httpd.conf.  Is this how
it should be?  From the documentation in 'Writing Apache Modules ..'
it doesn't seem like it is, at least not to me.


(bo)




Compilation recommendations.

2000-09-26 Thread Lord Vorp

Hi all!

I run mod_perl for my webservers and it's pretty darn nice... ;-)

However, I see comments like, 'Oh, that was a bug log ago fixed in the CVS'
and then I cringe:
Building mod_perl like I want it is not a process I've ever been able to get
"simple."

My environment is RedHat 6.2, but RedHat ships Apache w/ Mod_perl as a DSO.
That causes me absolutely NOTHING BUT PROBLEMS, so...

I took the apache source RPM and expanded it (with RedHat patches), then
expanded mod_perl the same way, and hand-built a makepl_args.mod_perl to
attempt to get a (mostly) RedHat-style httpd with static mod_perl.

In a word, yuck:

APACHE_SRC=../apache-1.3.9/src \
DO_HTTPD=1 \
USE_APACI=1 \
EVERYTHING=1 \
APACI_ARGS=--prefix=/usr --with-layout=RedHat --add-module=/usr/src/redhat/S
OURCES/mod_bandwidth.c --add-module
=/usr/src/redhat/SOURCES/mod_put.c --enable-module=all --enable-shared=max -
-disable-rule=WANTHSREGEX --disable-module=auth_dbm --with-perl=/usr/bin/per
l --enable-suexec --suexec-docroot=/home/httpd/html --suexec-caller=nobody -
-disable-shared=perl

cd mod_perl-#.##
make
make install
cd ../apache-#.#.#
make install

Is there an easier/cleaner way to do this???

Any suggestions would be very welcome.

L8r,
L V




RE: PerlAddVar bug

2000-09-26 Thread Doug MacEachern

On Thu, 6 Jul 2000, Geoffrey Young wrote:
 
 I guess my expectation is that $r-dir_config('MyVar') and
 $r-dir_config-get('MyVar') should inherit equally, which as far as I can
 tell, they don't.  PerlSetVar or PerlAddVar - it makes no difference.

the problem is related to the Apache::Server-dir_config support.  in the
directive handler, if path was NULL, the var was set/add-ed only to the
server_rec-module_config.  $r-dir_config falls back to the
server_rec-module_config  if the var is not found in
request_rec-per_dir_config, but $r-dir_config-get does not.  the patch
below fixes the problem, works just as PerlSetEnv does.  the key/val is
always added to the per-dir table, and also added to the per-server table
is path == NULL, for use at startup time.

p.s.
i also just committed a change so PerlAddVar is now an ITERATE2 rather
than TAKE 2, so you can say:

PerlAddVar Key val-one val-two val-three

Index: src/modules/perl/perl_config.c
===
RCS file: /home/cvs/modperl/src/modules/perl/perl_config.c,v
retrieving revision 1.102
diff -u -r1.102 perl_config.c
--- src/modules/perl/perl_config.c  2000/09/22 18:52:00 1.102
+++ src/modules/perl/perl_config.c  2000/09/26 18:29:51
@@ -717,17 +717,17 @@
 
 CHAR_P perl_cmd_var(cmd_parms *cmd, void *config, char *key, char *val)
 {
+perl_dir_config *rec = (perl_dir_config *)config;
 MP_TRACE_d(fprintf(stderr, "perl_cmd_var: '%s' = '%s'\n", key, val));
-if (cmd-path) {
-perl_dir_config *rec = (perl_dir_config *) config;
-if (cmd-info) {
-table_add(rec-vars, key, val);
-}
-else {
-table_set(rec-vars, key, val);
-}
+
+if (cmd-info) {
+table_add(rec-vars, key, val);
 }
 else {
+table_set(rec-vars, key, val);
+}
+
+if (cmd-path == NULL) {
 dPSRV(cmd-server);
 if (cmd-info) {
 table_add(cls-vars, key, val);




Re: dir_config and Apache::Table confusion

2000-09-26 Thread Doug MacEachern

On 26 Sep 2000, Bjørn Ola Smievoll wrote:

 Works for me too when PerlSetVar is inside a Location /foo, but not
 when it's defined outside, in the 'root' of httpd.conf.  Is this how
 it should be?  From the documentation in 'Writing Apache Modules ..'
 it doesn't seem like it is, at least not to me.

ah, see the patch i just posted, it should fix this problem too.




Re: Compilation recommendations.

2000-09-26 Thread darren chamberlain

Lord Vorp ([EMAIL PROTECTED]) said something to this effect:
 Is there an easier/cleaner way to do this???


Yes:

# cat  ~/build_mod_perl
perl Makefile.PL APACHE_SRC=../apache-1.3.9/src \
DO_HTTPD=1 \
USE_APACI=1 \
EVERYTHING=1 \
APACI_ARGS='--prefix=/usr \
   --with-layout=RedHat --add-module=/usr/src/redhat/SOURCES/mod_bandwidth.c \
   --add-module=/usr/src/redhat/SOURCES/mod_put.c --enable-module=all \
   --enable-shared=max --disable-rule=WANTHSREGEX --disable-module=auth_dbm \
   --with-perl=/usr/bin/perl --enable-suexec --suexec-docroot=/home/httpd/html \
   --suexec-caller=nobody --disable-shared=perl'

cd mod_perl-#.##
make
make install
cd ../apache-#.#.#
make install
^D

# cd /usr/local/src
# sh ~/build_mod_perl
#

If you think this is hard, try it without make.

(darren)

-- 
Blind faith in anything, even your leaders, will get you killed.
-- Bruce Springsteen



RE: Apache::Request-new() problem

2000-09-26 Thread Herrington, Jack

I'm using Mason in process with mod_perl.  I have also tried using mod_perl
handlers direct with Apache::Request with no success.

-Original Message-
From: Doug MacEachern [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, September 26, 2000 10:23 AM
To: Herrington, Jack
Cc: [EMAIL PROTECTED]
Subject: Re: Apache::Request-new() problem


On Mon, 25 Sep 2000, Herrington, Jack wrote:

 I have the same problem as one of the previous reporters with
 Apache::Request-new().  The problem occurs whether I call it after a
'use'
 or after a 'PerlModule' load.  Perl returns the no 'new' method could be
 found for Apache::Request.

sounds to me like your script is not running under mod_perl.
Apache/Request.pm calls this to bootstrap the xs interface:

__PACKAGE__-mod_perl::boot($VERSION);

if you are not running under mod_perl ($ENV{MOD_PERL} is not set), then
the interface is not bootstrapped.  this is done so 'perl -c' can be run
on scripts that 'use Apache::*' with apis only available when running
inside the server.



mod-perl as DSO (solaris)

2000-09-26 Thread Ricardo Stella

Solaris 2.8
Apache 1.3.12
GCC 2.95.2
Perl 5.6.0
Enterprise 250 (64bitish)
Modperl 1.24

I can't get modperl compiled as a DSO neither via the 'flexible-method'
nor the APXS method.

The first method, seg faults.

The second method won't configure, stating I should not build mod-perl
as a DSO or compile perl with -Ubincompat5005.

My current perl was compiled with bincompat5005 (perl -V:bincompat5005
shows as 'defined')

So, is this working at all ???  Searching the archives, all I found was
related to 1.23.  I also tried specifically setting 

CFLAGS=-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fno-strict-aliasing

when compiling apache, but did not help.

TIA.



-- 
--
 Ricardo Stella  O.I.T.
 (609)896-5000 x7436   _suAve_   Rider University
  *** Remove 'no-spam' from e-mail address before replying.  ***

begin:vcard 
adr;dom:;;;Lawrenceville;NJ;08648;
adr:;;2083 Lawreceville Road;Lawrenceville;NJ;08648;
n:Stella;Ricardo
tel;fax:1-609-219-4994
tel;work:1-609-896-5000 x7436
x-mozilla-html:FALSE
url:http://poseidon.rider.edu
org:Rider University;O.I.T.
version:2.1
title:Manager
x-mozilla-cpt:;-9584
fn:Ricardo Stella
end:vcard



Re: Apache::DProf tip

2000-09-26 Thread Doug MacEachern

On Sat, 10 Jun 2000, Perrin Harkins wrote:

 Here's something that might be obvious to others but took me a while to
 figure out:
 
 If you want to get useful profiling information, you need to initialize
 the debugger before your modules get compiled.  If you pull in your
 modules from startup.pl, you can accomplish this by putting a block like
 this in your httpd.conf before the "PerlRequire startup.pl" statement:
 
 Perl
 use Apache::DProf;
 use Apache::DB;
 Apache::DB-init;
 /Perl
 
 The "PerlModule Apache::DProf" directove suggested in the Apache::DProf
 docs also seems to work, but be careful because load order seems to matter
 here.

the Apache::DB docs explain this:

=item init

This function initializes the Perl debugger hooks without actually
starting the interactive debugger.  In order to debug a certain piece
of code, this function must be called before the code you wish debug
is compiled.

--

it should probably be made more clear though, maybe a comment in the
config example.




RE: PerlAddVar bug

2000-09-26 Thread Geoffrey Young



 -Original Message-
 From: Doug MacEachern [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, September 26, 2000 2:35 PM
 To: Geoffrey Young
 Cc: 'Eric Cholet'; Matt Sergeant; [EMAIL PROTECTED]
 Subject: RE: PerlAddVar bug
 
 
 On Thu, 6 Jul 2000, Geoffrey Young wrote:
  
  I guess my expectation is that $r-dir_config('MyVar') and
  $r-dir_config-get('MyVar') should inherit equally, which 
 as far as I can
  tell, they don't.  PerlSetVar or PerlAddVar - it makes no 
 difference.
 
 the problem is related to the Apache::Server-dir_config 
 support.  in the
 directive handler, if path was NULL, the var was set/add-ed 
 only to the
 server_rec-module_config.  $r-dir_config falls back to the
 server_rec-module_config  if the var is not found in
 request_rec-per_dir_config, but $r-dir_config-get does 
 not.  the patch
 below fixes the problem, works just as PerlSetEnv does.  the 
 key/val is
 always added to the per-dir table, and also added to the 
 per-server table
 is path == NULL, for use at startup time.

groovy - the patch seems to work just fine (you've been busy, it seems :)

 
 p.s.
 i also just committed a change so PerlAddVar is now an ITERATE2 rather
 than TAKE 2, so you can say:
 
 PerlAddVar Key val-one val-two val-three

that works ok too.

Any particular reason for keeping PerlSetVar TAKE2?

anyway, thanks again for the efforts

--Geoff

 
 Index: src/modules/perl/perl_config.c
 ===
 RCS file: /home/cvs/modperl/src/modules/perl/perl_config.c,v
 retrieving revision 1.102
 diff -u -r1.102 perl_config.c
 --- src/modules/perl/perl_config.c2000/09/22 18:52:00 1.102
 +++ src/modules/perl/perl_config.c2000/09/26 18:29:51
 @@ -717,17 +717,17 @@
  
  CHAR_P perl_cmd_var(cmd_parms *cmd, void *config, char *key, 
 char *val)
  {
 +perl_dir_config *rec = (perl_dir_config *)config;
  MP_TRACE_d(fprintf(stderr, "perl_cmd_var: '%s' = 
 '%s'\n", key, val));
 -if (cmd-path) {
 -perl_dir_config *rec = (perl_dir_config *) config;
 -if (cmd-info) {
 -table_add(rec-vars, key, val);
 -}
 -else {
 -table_set(rec-vars, key, val);
 -}
 +
 +if (cmd-info) {
 +table_add(rec-vars, key, val);
  }
  else {
 +table_set(rec-vars, key, val);
 +}
 +
 +if (cmd-path == NULL) {
  dPSRV(cmd-server);
  if (cmd-info) {
  table_add(cls-vars, key, val);
 



Re: env in background process

2000-09-26 Thread Doug MacEachern

On Mon, 14 Aug 2000, Niraj Sheth wrote:

 Hi,
 
 I am having very strange problem with environment variables.
 
 From Apache::PerlRun script(cgi) I am setting env and firing background
 process ..
 system("$command ") (or print `$command `;)
 
 now looks like environment variable being persistence b/w different
 requests ONLY in background process. so it's looks to me that mod_perl
 is setting proper "Perl Level" env but failing to reset env at "c level"
 or "process level". I know it's sounds very weird.
 /perl-status?env is printing correctly but my background process
 ($command) is printing few extra env, which i set it in different cgi
 script.
 
 e.g. "script1.pl" is setting $ENV{foo1} = "foo1" and firing print
 `command1 `;
 and "script2.pl" is setting $ENV{foo2} = "foo2" and firing print
 `command2 `;
 
 after few hits both env(foo1 and foo2) are visible to both background
 processes.
 while /perl-status?env is displaying correctly.
 Here command1 and command2(perl scripts) are just printing env
 
 Apache/1.3.9 (Unix) mod_perl/1.21

with the test case below, i get the expected results:

env is missing MOD_PERL

all of %ENV should be inherited except for this one.  if you have a
small test case that i can drop in and run (small like the one below),
i'll take a look.

my $r = shift;

$r-send_http_header;

local $ENV{PATH} = '/usr/bin';

$ENV{PACKAGE} = __PACKAGE__;

my @env = `env`;
my %env;

for (@env) {
chomp;
my($k,$v) = split '=';
$env{$k} = $v;
}

while (my($k,$v) = each %ENV) {
next if exists $env{$k};
print "env is missing $k\n";
}






Re: Multiple PerlAccessHandlers problem.

2000-09-26 Thread Doug MacEachern

On Tue, 15 Aug 2000, Trevor Phillips wrote:

 I'm having problems with a mix of PerlAccessHandlers. I have two handlers, and
 it is required that one be defined in a Location block, and the other
 currently in .htaccess' as required.
 
 The problem is that the one in the .htaccess is being completely ignored when I
 have the one in the Locate block. ie;
 
 In httpd.conf:
 
 Location /
 PerlAccessHandler XXX
 /Location
 
 In a .htaccess:
 
 PerlAccessHandler YYY
 
 So, XXX takes effect, but YYY is ignored.
 
 If I take out the Location one and have both in the .htaccess:
 
 PerlAccessHandler XXX YYY
 
 Or even on separate lines:
 
 PerlAccessHandler XXX
 PerlAccessHandler YYY
 
 Then it all works, but when XXX is in a Location, it overrides all .htaccess
 references.
 
 Is this supposed to be the correct behaviour? How do I get the behaviour I
 want? (One in a Location, and one in .htaccess).

it is the expected behavior, the config merge routine just checks if the
new config Perl*Handler array exists, if so, uses that, otherwise points
at the base config Perl*Handler array.  it does not attempt to merge the
values of both arrays.  it was in the ToDo file at one point to merge the
arrays as you expected, but it now lives in the 2.0 ToDo file.




RE: env in background process

2000-09-26 Thread Doug MacEachern

On Tue, 15 Aug 2000, Niraj Sheth wrote:
 
 so why dump_env is getting both?
 If I either uncomment "local %ENV = %ENV;" in script or put "%ENV = ();"
 in PerlCleanupHandler then dump_env is working fine.
 I tried both Apache::PerlRun and Apache::Registry which same result.

oh whoops, you did send a test case.  i think the problem is that mod_perl
only clears the Perl side of %ENV, so the underlying C environ array is
not modified.  if we do that than other problems pop up.  the best
approach for the moment is to use:

local $ENV{FOO1} = 'foo1';

print `dump_env`;




Re: Strange exit error

2000-09-26 Thread Doug MacEachern

On Sat, 19 Aug 2000, Ron Pero wrote:

 Am running
 In PerlRun
 $ENV{MOD_PERL} = mod_perl/1.21
 This is perl, version 5.005_03 built for i386-freebsd
 It is on iserver, which has a virtual root system
 Am also running dbi.
 
 When the script calls "exit", it produces an error:
  at /usr/local/etc/httpd/cgi-bin/myscript.cgi line 366.
  
 line 366 is the line that contains "exit".
 There is no descriptive clue as to what the error is.
 
 This does not happen while running the script in cgi mode.
 
 I've looked in the mod_perl guide, and tried different ways of exiting
 (Apache::exit, etc), but same thing. And besides, exit should work just
 fine under PerlRun.
 
 Can anyone clue me in as to what this very cryptic error is?

it's been explained a few times in the past, i don't feel like doing it
again or searching the docs/archives.  in short, calling exit() is bad,
avoid it.  Apache::exit overrides the builtin exit() to prevent some
of the badness, but in a way that can be tripped up leading to that
warning message.  it is only a warning, if you want to get rid of it,
don't use exit().




RE: Can't locate object method No via package such

2000-09-26 Thread Rob Bloodgood

Shoulda thought about your answer first, Doug.  :-)

I see this type of message ("error at /dev/null") when my mod_perl scripts
give warnings -w style instead of $r-warn.  For example, HTML::Embperl, or
Apache::Registry both do this.

The nature of the error message sez to me there is a mishandled error
somewhere, like possibly an eval that is turning into a method call:

eval { # read file here
   # file doesn't exist
   # error is
   No such file or directory
   # which is parsed by perl to something like:
   # such-No (file or directory)
 };

Which further tends to suggest that a necessary environment variable for SSL
is either not defined or pointing to the wrong place??

I would suggest *never* disregarding configtest errors... one poorly
indicative error message can be the final gasp of a long string of errors
caused by a simple typo or whatever several layers deep.

Good luck!

L8r,
L V

-Original Message-
From: Alan E. Derhaag [mailto:[EMAIL PROTECTED]]
Sent: Monday, September 25, 2000 7:29 PM
To: Doug MacEachern
Cc: [EMAIL PROTECTED]
Subject: Re: Can't locate object method "No" via package "such"


Doug MacEachern [EMAIL PROTECTED] writes:

 On 4 Sep 2000, Alan E. Derhaag wrote:

  I upgraded to openssl-0.9.5a and recompiled apache w/mod_ssl and
  mod_perl defining the SSL_BASE to the apache src and now the thing
  won't start and complains about:
 
   Can't locate object method "No" via package "such" at /dev/null line 1.

 looks to me like /dev/null is broken.  if you run:
 % cat /dev/null


Good try, but /dev/null is not broken on my machine.

I finally gave up and eliminated the DSO version by compiling two
versions of httpd.  Both include mod_ssl but the Engine is only turned
on with the light server.

I did find a slight problem when running `configtest' but I doubt that
that could have been the problem.

--




Re: Building modperl as a DSO in Apache_1.3.12

2000-09-26 Thread Doug MacEachern

On Tue, 22 Aug 2000, Kairam, Raj wrote:

 I am trying to build modperl ( mod_perl-1.24 ) as DSO in to Apache (
 apache_1.3.12 ) on a host running HP-UX 11.0

   ld: Unrecognized argument: -Wl -E
   ld: Usage: ld flags ... files ...
 The output of make is captured in the following attachment
  make_0818.txt 
 The last line in the above file indicates the 'ld' command and the arguments
 '-Wl -E' are in that long line halfway.
 
 When I look at the generated Makefile, I see the two lines
 CCCDLFLAGS = +z
 CCDLFLAGS = -Wl, E -Wl,-B,deferred
 
 How can I avoid this error ?. Any of you working with mod_perl on a HP-UX
 box encountered this situation ?.

your 'perl -V' would help alot, but i'm guessing if you run
'make LD=cc', that would fix the problem.




RE: PerlAddVar bug

2000-09-26 Thread Doug MacEachern

On Tue, 26 Sep 2000, Geoffrey Young wrote:
 
 groovy - the patch seems to work just fine (you've been busy, it seems :)

cool!

  p.s.
  i also just committed a change so PerlAddVar is now an ITERATE2 rather
  than TAKE 2, so you can say:
  
  PerlAddVar Key val-one val-two val-three
 
 that works ok too.
 
 Any particular reason for keeping PerlSetVar TAKE2?

not that i can think of, it should have been ITERATE2 the first time
around.




Re: tracking down why a module was loaded?;

2000-09-26 Thread Alexander Farber (EED)

Doug MacEachern wrote:
  modperl is the best kept secret on the net. Shame!
 seems to generate plenty of list traffic for a "secret" ;)

Don't you all think, that mod_perl isn't promoted enough and 
this will kill it someday, despite its technical goodness?

- There are no articles in the "mainstream" computer press 
  (like cnet.com, www.ix.de, etc) about mod_perl. 

- There are no benchmarks, comparing to Java/Coldfusion/whatever. 

- I work at a big telco, and no one cares/knows here about 
  mod_perl (except our intranet-webmaster, who still prefers 
  PHP, since it makes him less trouble).

- People, who have heard about mod_perl, are looking for servlet/
  JSP-programmers, because mod_perl-coders are hard to find.



Re: Apache::DProf tip

2000-09-26 Thread Perrin Harkins

On Tue, 26 Sep 2000, Doug MacEachern wrote:
 the Apache::DB docs explain this:

The connection between Apache::DProf and calling something in Apache::DB
was not obvious to me until I thought about how DProf works.

 it should probably be made more clear though, maybe a comment in the
 config example.

I'd be happy to write up a little documentation patch for it.  I'll send
it to you.

- Perrin




Re: PATCH: AIX build fix for the apaci style build

2000-09-26 Thread Doug MacEachern

On Thu, 24 Aug 2000, Jens-Uwe Mager wrote:

 Well, I have only used the apxs DSO style build previously and did not
 notice that for linking modperl statically into httpd (apaci style)
 there are small problems due to the AIX specifix .exp file business. The
 following patch fixes this, in particular it adds the mod_perl.exp file
 as an export file while httpd is linked to export the extra symbols from
 modperl needed by libapreq and Embperl. It also adds logic to
 Apache::src to find the httpd.exp if modperl is not a DSO.

applied, thanks!
 
 While doing that I noticed that mod_include if built as DSO for PERL_SSI
 needs to reference the perl symbols but the build procedure does only
 reference the httpd.exp file and not the perl.exp file, so this will not
 work yet. I had to use a config like this:
 
 perl Makefile.PL EVERYTHING=1 DO_HTTPD=1 USE_APACI=1 \
   APACI_ARGS="--enable-module=most --enable-shared=max --disable-shared=perl 
--disable-shared=include"

you should also be able to use PERL_SSI=0

hmm, Makefile.PL could probably detect if mod_include is static or not,
i'm not sure it's worth it though.




Re: PerlModule in .htaccess (for auth) faults (possible patch forperl_config.c)

2000-09-26 Thread Doug MacEachern

On 22 Aug 2000, Andrew Gideon wrote:
... 
 My .htaccess file contains:
 
   PerlModule  Apache::TAGXSessionAuth 
   PerlAuthenHandler   Apache::TAGXSessionAuth-authen 
   PerlAuthzHandlerApache::TAGXSessionAuth-authz 
 
 After attaching to a child process and getting the segv, 
 the stack looks like:
 
   (gdb) where 
   #0  0x107810 in ap_push_array ()

thanks for digging into this andrew.
i think the problem is related to the perl_merge_server_config routine:
#if 0
/* We don't merge these because they're inlined */
mrg-PerlModule = append_arrays(p, add-PerlModule, base-PerlModule);
mrg-PerlRequire = append_arrays(p, add-PerlRequire, base-PerlRequire);
#endif

this means that VirtualHost configs have NULL for both arrays.  this is
fine at startup time, since mod_perl only uses the base_server config.
a simple fix is to not push if either is NULL:

Index: src/modules/perl/perl_config.c
===
RCS file: /home/cvs/modperl/src/modules/perl/perl_config.c,v
retrieving revision 1.103
diff -u -u -r1.103 perl_config.c
--- src/modules/perl/perl_config.c  2000/09/26 20:05:22 1.103
+++ src/modules/perl/perl_config.c  2000/09/26 20:59:48
@@ -587,8 +587,11 @@
return NULL;
}
 }
-*(char **)push_array(cls-PerlModule) = pstrdup(parms-pool, arg);
 
+if (cld-PerlModule) {
+*(char **)push_array(cls-PerlModule) = pstrdup(parms-pool, arg);
+}
+
 #ifdef PERL_SECTIONS
 if(CAN_SELF_BOOT_SECTIONS)
perl_section_self_boot(parms, dummy, arg);
@@ -618,7 +621,9 @@
}
 }
 
-*(char **)push_array(cls-PerlRequire) = pstrdup(parms-pool, arg);
+if (cls-PerlRequire) {
+*(char **)push_array(cls-PerlRequire) = pstrdup(parms-pool, arg);
+}
 
 #ifdef PERL_SECTIONS
 if(CAN_SELF_BOOT_SECTIONS)




Re: Apache::DProf tip

2000-09-26 Thread Doug MacEachern

On Tue, 26 Sep 2000, Perrin Harkins wrote:

 On Tue, 26 Sep 2000, Doug MacEachern wrote:
  the Apache::DB docs explain this:
 
 The connection between Apache::DProf and calling something in Apache::DB
 was not obvious to me until I thought about how DProf works.

yeah, i was actually surprised to find that it was documented anywhere ;)
 
 I'd be happy to write up a little documentation patch for it.  I'll send
 it to you.

that'd be great, thanks!




Re: Compilation recommendations.

2000-09-26 Thread Paul Lindner

See http://people.redhat.com/plindner/apache/ for a static mod_perl
that runs well on redhat.

I am putting src and i386 rpms there..

Note that this is incomplete.  You'll need to roll your own conf files...

This also includes some oracle and php code too.  Thus it is blessed
'apache-heavy'

I would love to hear feedback on how to improve this distribution.

Thanks.


On Tue, Sep 26, 2000 at 02:45:10PM -0400, darren chamberlain wrote:
 Lord Vorp ([EMAIL PROTECTED]) said something to this effect:
  Is there an easier/cleaner way to do this???
 
 
 Yes:
 
 # cat  ~/build_mod_perl
 perl Makefile.PL APACHE_SRC=../apache-1.3.9/src \
 DO_HTTPD=1 \
 USE_APACI=1 \
 EVERYTHING=1 \
 APACI_ARGS='--prefix=/usr \
--with-layout=RedHat --add-module=/usr/src/redhat/SOURCES/mod_bandwidth.c \
--add-module=/usr/src/redhat/SOURCES/mod_put.c --enable-module=all \
--enable-shared=max --disable-rule=WANTHSREGEX --disable-module=auth_dbm \
--with-perl=/usr/bin/perl --enable-suexec --suexec-docroot=/home/httpd/html \
--suexec-caller=nobody --disable-shared=perl'
 
 cd mod_perl-#.##
 make
 make install
 cd ../apache-#.#.#
 make install
 ^D
 
 # cd /usr/local/src
 # sh ~/build_mod_perl
 #
 
 If you think this is hard, try it without make.
 
 (darren)
 
 -- 
 Blind faith in anything, even your leaders, will get you killed.
   -- Bruce Springsteen

-- 
Paul Lindner
[EMAIL PROTECTED]
Red Hat Inc.



Re: make tar_Apache broken?

2000-09-26 Thread Doug MacEachern

On Wed, 30 Aug 2000, Jesse Erlbaum wrote:

 Hey Doug  mod_perl'ers!
 
 I tried to build mod_perl and use "make tar_Apache" to build a distributable
 tar for other same-architecture machines, without success.
... 
 If this is correct, and not an artifact of trying to build outside of the
 normal paths, this would seem to indicate that there is a small flaw in the
 Makefile.PL which references the wrong directories.  If that is the case, I
 have created a patch which appears to correct the problem:

applied, thanks!




Re: Apache::DB in emacs

2000-09-26 Thread rwk

I regret I was not subscribed for a few days.

If anyone knows anything about this: "some 'remote' hooks in the Perl
debugger" and they posted to this list, please let me know at:
[EMAIL PROTECTED]

I am now re-subscribed.

Thanks,
Dick


  Can anyone tell me if there is a way to run mod_perl's Apache::DB under
  emacs?
 
 there are some 'remote' hooks in the Perl debugger (perl5db.pl), but i've
 only heard about it, never tried, so not sure if that is a possible
 solution.  i don't think Apache::DB as-is will run under emacs, unless
 somebody with enough emacs-lisp-fu can rig something up to run 'httpd -X
 -DPERLDB' under emacs.
 



Remote Hosting

2000-09-26 Thread Allen Wilson

Does anyone have an idea of how to set up a remote host request. I am attempting
to set up a web system where the user makes a request and it is process from one
server to another. The remote server will return a file that will be formatted
in a web page. 

I already have the formatting done...it is the connection and requesting from
the remote server giving me the problem. I tried to run the remote shell (remsh
) but that failed.

Any ideas would be appreciate.

Allen



perl installation on hpux : cc vs gcc

2000-09-26 Thread Dhananjay Naniwadekar


I am trying to install perl-5.6.0 on hpux.
It is choosing cc as the c compiler. I don't know why. If I install an
earlier version
of perl, it chooses gcc.
I have an env-variable named CC which is set to gcc .
My $PATH first lists the dir which contains "gcc" executable, and then the
dir which contains "cc" executable. e.g; my gcc is in /opt/gcc/bin ; my cc
is in /usr/bin,
my $PATH is ":/opt/gcc/bin::/usr/bin:..."

Any idea why perl installation chooses cc as the c compiler?

Another Q is if I override the default of cc and set gcc as compiler
instead, I am getting errors.
My setting are :
cc flags : -D_HPUX_SOURCE -Aa -fno-strict-aliasing -I/usr/local/include
ld flags : -Wl,+vnocompatwarnings -L/usr/local/lib

The error I get is :
*Initialization*:1: missing token-sequence in `#assert'
I can't compile the test program.
(The supplied flags or libraries might be incorrect.)

You have a BIG problem.  Shall I abort Configure [y]

Please advise.

- nani (Dhananjay Naniwadekar)





RE: Remote Hosting

2000-09-26 Thread Christian Gilmore

It sounds like you're looking for a proxy. If that's the case, there are a
huge variety of options starting with apache's own built-in mod_proxy.

Regards,
Christian

 -Original Message-
 From: Allen Wilson [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, September 26, 2000 3:54 PM
 To: Modperl
 Subject: Remote Hosting


 Does anyone have an idea of how to set up a remote host
 request. I am attempting
 to set up a web system where the user makes a request and it
 is process from one
 server to another. The remote server will return a file that
 will be formatted
 in a web page.

 I already have the formatting done...it is the connection and
 requesting from
 the remote server giving me the problem. I tried to run the
 remote shell (remsh
 ) but that failed.

 Any ideas would be appreciate.

 Allen





RE: Remote Hosting

2000-09-26 Thread jbodnar

Take a look at Apache::ProxyStuff. It may do exactly what you want and if it
doesn't it'll give you some ideas on how to do what you want.

On 26-Sep-2000 Allen Wilson wrote:
 Does anyone have an idea of how to set up a remote host request. I am
 attempting
 to set up a web system where the user makes a request and it is process from
 one
 server to another. The remote server will return a file that will be
 formatted
 in a web page. 
 
 I already have the formatting done...it is the connection and requesting from
 the remote server giving me the problem. I tried to run the remote shell
 (remsh
 ) but that failed.
 
 Any ideas would be appreciate.
 
 Allen

-- 
Jason Bodnar + [EMAIL PROTECTED] + Team Linux

If there was any justice, my face would be on a bunch of crappy merchandise!

-- Homer Simpson
   Flaming Moe's




Why isn't PerlSetEnv working for me?

2000-09-26 Thread Keith G. Murphy

I'm running Apache 1.3.9 with mod_perl embedded, on Debian GNU/Linux.

I have the following lines towards the end of my httpd.conf:

PerlSetEnv PERL5LIB /usr/local/MyPerl/lib
PerlRequire startup.pl
Include perllocs.conf

However, upon system startup, my startup.pl fails because it can't find
a particular module in the @INC list.

If I start Apache from the command line, it works.  This is undoubtedly
because PERL5LIB is set up in my /etc/profile, to the same path.

I've looked at this until I'm crosseyed.  Seemingly PerlSetEnv just
doesn't work.

Any ideas?  Yes, I know the workaround: 'use lib' in startup.pl.  But
why?



Re: Why isn't PerlSetEnv working for me?

2000-09-26 Thread Chris Winters

* Keith G. Murphy ([EMAIL PROTECTED]) [000926 18:43]:
 I'm running Apache 1.3.9 with mod_perl embedded, on Debian GNU/Linux.
 
 I have the following lines towards the end of my httpd.conf:
 
 PerlSetEnv PERL5LIB /usr/local/MyPerl/lib
 PerlRequire startup.pl
 Include perllocs.conf
 
 However, upon system startup, my startup.pl fails because it can't find
 a particular module in the @INC list.
 
 If I start Apache from the command line, it works.  This is undoubtedly
 because PERL5LIB is set up in my /etc/profile, to the same path.
 
 I've looked at this until I'm crosseyed.  Seemingly PerlSetEnv just
 doesn't work.
 
 Any ideas?  Yes, I know the workaround: 'use lib' in startup.pl.  But
 why?

There's another workaround:

in httpd.conf:

Perl 
  use lib qw( /usr/local/MyPerl/lib ); 
/Perl

Pretty painless :)

Chris

-- 
Chris Winters
Senior Internet Developerintes.net
[EMAIL PROTECTED]   http://www.intes.net/
Integrated hardware/software solutions to make the Internet work for you.



RE: Why isn't PerlSetEnv working for me?

2000-09-26 Thread Christian Gilmore

If you have a startup.pl, why not just

  use lib qw(/usr/local/MyPerl/lib);

within the startup.pl script?

Regards,
Christian

 -Original Message-
 From: Keith G. Murphy [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, September 26, 2000 5:32 PM
 To: [EMAIL PROTECTED]
 Subject: Why isn't PerlSetEnv working for me?
 
 
 I'm running Apache 1.3.9 with mod_perl embedded, on Debian GNU/Linux.
 
 I have the following lines towards the end of my httpd.conf:
 
 PerlSetEnv PERL5LIB /usr/local/MyPerl/lib
 PerlRequire startup.pl
 Include perllocs.conf
 
 However, upon system startup, my startup.pl fails because it 
 can't find
 a particular module in the @INC list.
 
 If I start Apache from the command line, it works.  This is 
 undoubtedly
 because PERL5LIB is set up in my /etc/profile, to the same path.
 
 I've looked at this until I'm crosseyed.  Seemingly PerlSetEnv just
 doesn't work.
 
 Any ideas?  Yes, I know the workaround: 'use lib' in startup.pl.  But
 why?
 



Core file (debugging info turned on/stack trace)

2000-09-26 Thread Shane Adams
Title: Core file (debugging info turned on/stack trace)





Apache 1.3.12, mod_perl 1.24, Perl 5.6.0, Redhat 6.1


...
Program terminated with signal 11, Segmentation fault.
...
0 0x814abd4 in Perl_sv_setsv (dstr=0x8d34514, sstr=0x84afba4) at sv.c:2774
#1 0x813b6b3 in Perl_pp_sassign () at pp_hot.c:117
#2 0x813aeda in Perl_runops_debug () at run.c:56
#3 0x80e4b2f in S_call_body (myop=0x72f0, is_eval=0) at perl.c:1761
#4 0x80e4415 in perl_call_sv (sv=0x8845bd4, flags=2) at perl.c:1638
#5 0x812a892 in Perl_vdie (
 pat=0x81d46a0 Can't use string (\%.32s\) as %s ref while \strict refs\ in use,
 args=0x736c) at util.c:1532
#6 0x812aa71 in Perl_die (
 pat=0x81d46a0 Can't use string (\%.32s\) as %s ref while \strict refs\ in use)
 at util.c:1567
#7 0x8155127 in Perl_pp_rv2gv () at pp.c:249
#8 0x813aeda in Perl_runops_debug () at run.c:56
#9 0x80e4b2f in S_call_body (myop=0x74b8, is_eval=0) at perl.c:1761
#10 0x80e4780 in perl_call_sv (sv=0x82e7bcc, flags=4) at perl.c:1677
#11 0x8075aac in perl_call_handler (sv=0x82e7bcc, r=0x88ac844, args=0x0)
 at mod_perl.c:1643
#12 0x8074fd8 in perl_run_stacked_handlers (hook=0x81ac879 PerlHandler, r=0x88ac844,
 handlers=0x876f72c) at mod_perl.c:1362
#13 0x80726a8 in perl_handler (r=0x88ac844) at mod_perl.c:905
#14 0x80a0913 in ap_invoke_handler ()
#15 0x80b3f29 in process_request_internal ()
#16 0x80b3f8c in ap_process_request ()
#17 0x80ab82e in child_main ()
#18 0x80aba6c in make_child ()
#19 0x80abde6 in perform_idle_server_maintenance ()
#20 0x80ac315 in standalone_main ()
#21 0x80ac8d3 in main ()



So far I've applied a mason related patch thanks to Doug, and a path on perl itself that was listed on this list. Still getting faults however, and they are frequent enough for me to worry about in a production scenario. We are using the HTML::Mason package if it helps any.




[ANNOUNCE] new module HTTPD::Bench::ApacheBench

2000-09-26 Thread Adi

Stas Bekman wrote:
 
  Before I upload it to CPAN, are there any objections to calling it
  "ApacheBench"?  Other names I considered are "Bench", "ab", "ABuse"... but
  ApacheBench I thought was the best because an m/Apache/ search on CPAN will find
  it.
 
 That's the proper name, since it's a glue code for ab, plus extra
 fuctionality. The only thing I'd add is a prefix so we could put other
 Benchmarking implementation under the same tree. Especially as you have
 mentioned in the pod it's not mod_perl specific. I'd go for
 HTTPD::Bench:: or HTTPDBench:: tree.

Ok, I've renamed it to HTTPD::Bench::ApacheBench.

 
 But you have already released it on CPAN, so I don't know... (I couldn't
 reply earlier since I was preaching mod_perl at YAPC::Europe, which was
 a very cool conference :)

It did go into CPAN but the metadata never got in, so it didn't show up on
searches.  I hope the rename doesn't affect anyone.

Hope you had fun at the conference.  I'll make it to one (one of these years).
:)

 
  Stas, hopefully I'll be able to integrate this with your new Apache::Benchmark
  module.  I haven't had time to look over yours fully, but I'm thinking your
  module will be a layer around this.  Currently Apache::Benchmark uses ab,
  right?  This module almost completely replaces ab.  There are a few features
  that still need to be added.
 
 Yup, cool. In fact you are welcome to take over it :) Apache::Benchmark
 shouldn't be depenfing on the actual engine used for Benchmarking. One
 should be able to plug any engine instead of ab.
 

Yes, I'll be looking at it extensively in the next few months.  So I might just
take it over. :)


--

The uploaded file

ApacheBench-0.51.tar.gz

has entered CPAN as

  file: $CPAN/authors/id/A/AD/ADIRAJ/ApacheBench-0.51.tar.gz
  size: 46603 bytes
   md5: d9e5bd55500da2c040fe88c4a08b69ae

No action is required on your part
Request entered by: ADIRAJ (Adi Fairbank)
Request entered on: Tue, 26 Sep 2000 16:18:49 GMT
Request completed:  Tue, 26 Sep 2000 16:19:31 GMT

Virtually Yours,
Id: paused,v 1.68 1999/10/22 14:39:12 k Exp k




Re: Why isn't PerlSetEnv working for me?

2000-09-26 Thread Stas Bekman

On Tue, 26 Sep 2000, Keith G. Murphy wrote:

 I'm running Apache 1.3.9 with mod_perl embedded, on Debian GNU/Linux.
 
 I have the following lines towards the end of my httpd.conf:
 
 PerlSetEnv PERL5LIB /usr/local/MyPerl/lib
 PerlRequire startup.pl
 Include perllocs.conf
 
 However, upon system startup, my startup.pl fails because it can't find
 a particular module in the @INC list.
 
 If I start Apache from the command line, it works.  This is undoubtedly
 because PERL5LIB is set up in my /etc/profile, to the same path.
 
 I've looked at this until I'm crosseyed.  Seemingly PerlSetEnv just
 doesn't work.
 
 Any ideas?  Yes, I know the workaround: 'use lib' in startup.pl.  But
 why?
 

http://thingy.kcilink.com/modperlguide/config/PerlSetVar_PerlSetEnv_and_PerlP.html

Regarding the setting of PerlPassEnv PERL5LIB in httpd.conf: if you turn
on taint checks (PerlTaintCheck On), $ENV{PERL5LIB} will be ignored
(unset). See the 'Switches -w, -T' section.

_
Stas Bekman  JAm_pH --   Just Another mod_perl Hacker
http://stason.org/   mod_perl Guide  http://perl.apache.org/guide 
mailto:[EMAIL PROTECTED]   http://apachetoday.com http://jazzvalley.com
http://singlesheaven.com http://perlmonth.com   perl.org   apache.org





Re: tracking down why a module was loaded?;

2000-09-26 Thread Gunther Birznieks

At 10:28 PM 9/26/2000 +0200, Alexander Farber (EED) wrote:
Doug MacEachern wrote:
   modperl is the best kept secret on the net. Shame!
  seems to generate plenty of list traffic for a "secret" ;)

Don't you all think, that mod_perl isn't promoted enough and
this will kill it someday, despite its technical goodness?

- There are no articles in the "mainstream" computer press
   (like cnet.com, www.ix.de, etc) about mod_perl.

- There are no benchmarks, comparing to Java/Coldfusion/whatever.

- I work at a big telco, and no one cares/knows here about
   mod_perl (except our intranet-webmaster, who still prefers
   PHP, since it makes him less trouble).

- People, who have heard about mod_perl, are looking for servlet/
   JSP-programmers, because mod_perl-coders are hard to find.

I unfortunately have to agree.

Depending on where you go Perl programmers may be easier to find that Java 
programmers, but finding an existing mod_perl programmer is not easy. It's 
doable, but not easy. And in the end, the salaries for mod_perl programmers 
are pretty high right now because of it -- so will a system really cost 
less to develop in mod_perl than in Java if Java programmers are becoming 
less expensive than mod_perl programmers?

We all have to do our part to evangelize mod_perl more. I think ISPs are 
really key here as I think I may have mentioned before. If you get the ISPs 
supporting and evangelizing mod_perl (and pre-installed mod_perl 
applications) then you will get users using it and liking it. How many ISPs 
advertise support for mod_perl? How many without charging like US$100 more 
a month on top of the normal account fees?

PHP comes with a lot of ISP accounts for free with no extra cost. Java does 
not yet, but I've started seeing ISPs starting to support Java in the low 
end shared server accounts...

Later,
Gunther


__
Gunther Birznieks ([EMAIL PROTECTED])
eXtropia - The Web Technology Company
http://www.extropia.com/




Re: tracking down why a module was loaded?;

2000-09-26 Thread ed

Gunther Birznieks wrote:

 I unfortunately have to agree.
 snip

 And in the end, the salaries for mod_perl programmers
 are pretty high right now because of it -- so will a system really cost
 less to develop in mod_perl than in Java if Java programmers are becoming
 less expensive than mod_perl programmers?
 /snip

Mod_perl programmers are more expensive as individuals,
because mod_perl is more powerful, and allows you access
to the Apache API; mod_perlers are more saavy.
One or two mod_perlers could do the
work of a java shop of ten in half the time. Still a savings.
Not to mention the hardware that goes with Java by fiat!

ed




RE: Core file (debugging info turned on/stack trace)

2000-09-26 Thread Shane Adams
Title: RE: Core file (debugging info turned on/stack trace)





Well I did a little more investigation - it seems that we are dieing in Expat.pm line 451. The offending Function is:


sub parse {
 my $self = shift;
 my $arg = shift;
 croak Parse already in progress (Expat) if $self-{_State_};
 $self-{_State_} = 1;
 my $parser = $self-{Parser};
 my $ioref;
 my $result = 0;


 if (defined $arg) {
 if (ref($arg) and UNIVERSAL::isa($arg, 'IO::Handler')) {
 $ioref = $arg;
 } else {
 eval {
 $ioref = *{$arg}{IO}; # *** = This is where we are losing it ***
 };
 undef $@;
 }
 }


 if (defined($ioref)) {
 my $delim = $self-{Stream_Delimiter};
 my $prev_rs;


 $prev_rs = ref($ioref)-input_record_separator(\n$delim\n)
 if defined($delim);


 $result = ParseStream($parser, $ioref, $delim);


 ref($ioref)-input_record_separator($prev_rs)
 if defined($delim);
 } else {
 $result = ParseString($parser, $arg);
 }


 $self-{_State_} = 2;
 $result or croak $self-{ErrorMessage};
}


As I recall, Doug, you helped me patch part of HTML::Mason dealing with typeglobs under an eval ... I believe that * is a typeglob in perl yes?


-Original Message-
From: Shane Adams 
Sent: Tuesday, September 26, 2000 4:16 PM
To: [EMAIL PROTECTED]
Subject: Core file (debugging info turned on/stack trace)



Apache 1.3.12, mod_perl 1.24, Perl 5.6.0, Redhat 6.1 
... 
Program terminated with signal 11, Segmentation fault. 
... 
0 0x814abd4 in Perl_sv_setsv (dstr=0x8d34514, sstr=0x84afba4) at sv.c:2774 
#1 0x813b6b3 in Perl_pp_sassign () at pp_hot.c:117 
#2 0x813aeda in Perl_runops_debug () at run.c:56 
#3 0x80e4b2f in S_call_body (myop=0x72f0, is_eval=0) at perl.c:1761 
#4 0x80e4415 in perl_call_sv (sv=0x8845bd4, flags=2) at perl.c:1638 
#5 0x812a892 in Perl_vdie ( 
 pat=0x81d46a0 Can't use string (\%.32s\) as %s ref while \strict refs\ in use, 
 args=0x736c) at util.c:1532 
#6 0x812aa71 in Perl_die ( 
 pat=0x81d46a0 Can't use string (\%.32s\) as %s ref while \strict refs\ in use) 
 at util.c:1567 
#7 0x8155127 in Perl_pp_rv2gv () at pp.c:249 
#8 0x813aeda in Perl_runops_debug () at run.c:56 
#9 0x80e4b2f in S_call_body (myop=0x74b8, is_eval=0) at perl.c:1761 
#10 0x80e4780 in perl_call_sv (sv=0x82e7bcc, flags=4) at perl.c:1677 
#11 0x8075aac in perl_call_handler (sv=0x82e7bcc, r=0x88ac844, args=0x0) 
 at mod_perl.c:1643 
#12 0x8074fd8 in perl_run_stacked_handlers (hook=0x81ac879 PerlHandler, r=0x88ac844, 
 handlers=0x876f72c) at mod_perl.c:1362 
#13 0x80726a8 in perl_handler (r=0x88ac844) at mod_perl.c:905 
#14 0x80a0913 in ap_invoke_handler () 
#15 0x80b3f29 in process_request_internal () 
#16 0x80b3f8c in ap_process_request () 
#17 0x80ab82e in child_main () 
#18 0x80aba6c in make_child () 
#19 0x80abde6 in perform_idle_server_maintenance () 
#20 0x80ac315 in standalone_main () 
#21 0x80ac8d3 in main () 



So far I've applied a mason related patch thanks to Doug, and a path on perl itself that was listed on this list. Still getting faults however, and they are frequent enough for me to worry about in a production scenario. We are using the HTML::Mason package if it helps any.




RE: env in background process

2000-09-26 Thread Sheth, Niraj

Thanks for looking at it.

I prefer "%ENV = ();" in PerlCleanupHandler handler. (as i don't have to
modify so many scripts).
I don't think it has any negative effect ...

-Niraj

 -Original Message-
 From: Doug MacEachern [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, September 26, 2000 3:32 PM
 To: Niraj Sheth
 Cc: [EMAIL PROTECTED]
 Subject: RE: env in background process
 
 
 On Tue, 15 Aug 2000, Niraj Sheth wrote:
  
  so why dump_env is getting both?
  If I either uncomment "local %ENV = %ENV;" in script or put 
 "%ENV = ();"
  in PerlCleanupHandler then dump_env is working fine.
  I tried both Apache::PerlRun and Apache::Registry which same result.
 
 oh whoops, you did send a test case.  i think the problem is 
 that mod_perl
 only clears the Perl side of %ENV, so the underlying C 
 environ array is
 not modified.  if we do that than other problems pop up.  the best
 approach for the moment is to use:
 
 local $ENV{FOO1} = 'foo1';
 
 print `dump_env`;
 



cvs commit: modperl/t/conf httpd.conf-dist

2000-09-26 Thread dougm

dougm   00/09/26 09:55:43

  Modified:.Changes ToDo Makefile.PL
   t/conf   httpd.conf-dist
  Log:
  'make test' config fixes for mod_ssl
  
  Revision  ChangesPath
  1.518 +4 -0  modperl/Changes
  
  Index: Changes
  ===
  RCS file: /home/cvs/modperl/Changes,v
  retrieving revision 1.517
  retrieving revision 1.518
  diff -u -r1.517 -r1.518
  --- Changes   2000/09/22 18:51:52 1.517
  +++ Changes   2000/09/26 16:55:35 1.518
  @@ -10,6 +10,10 @@
   
   =item 1.24_01-dev
   
  +'make test' config fixes for mod_ssl
  +[David Mitchell [EMAIL PROTECTED], Mark Murphy [EMAIL PROTECTED],
  +Stephen Schaefer [EMAIL PROTECTED]]
  +
   plug leak in DIR_MERGE, thanks to Matt Sergeant for the spot
   
   fixes to run and pass 'make test' on ActivePerl [Randy Kobes, Gerald Richter]
  
  
  
  1.250 +3 -2  modperl/ToDo
  
  Index: ToDo
  ===
  RCS file: /home/cvs/modperl/ToDo,v
  retrieving revision 1.249
  retrieving revision 1.250
  diff -u -r1.249 -r1.250
  --- ToDo  2000/09/26 15:33:56 1.249
  +++ ToDo  2000/09/26 16:55:36 1.250
  @@ -3,6 +3,9 @@
(well, close to it anyhow)
   ---
   
  +- segfaults with DBI-connect (mysql), reported that downgrade to
  +  1.21_03 cures
  +
   - Apache::read() does not clear $_[1] before appending data, bug or feature?
 [Cyrus Rahman [EMAIL PROTECTED]]
   
  @@ -68,8 +71,6 @@
   
   - sort out hpux Config.pm issues when $Config{ld} eq 'ld' but
 $Config{ldflags} have -Wl arguments
  -
  -- update mod_ssl test config
   
   - PERL_STATIC_EXTS doesnt work with USE_APACI=1
   
  
  
  
  1.167 +6 -0  modperl/Makefile.PL
  
  Index: Makefile.PL
  ===
  RCS file: /home/cvs/modperl/Makefile.PL,v
  retrieving revision 1.166
  retrieving revision 1.167
  diff -u -r1.166 -r1.167
  --- Makefile.PL   2000/09/13 06:06:40 1.166
  +++ Makefile.PL   2000/09/26 16:55:36 1.167
  @@ -135,6 +135,7 @@
  t/modules/ssi.t   
  t/logs/error_log
  t/conf/srm.conf
  +   t/conf/dev-null
  t/logs/httpd.pid
  src/modules/perl/mod_perl_version.h
  t/net/perl/cgi.pl
  @@ -873,6 +874,11 @@
   init_tests_and_config() if $USE_APXS;
   
   sub init_tests_and_config {
  +local *FH;
  +open FH, "t/conf/dev-null";
  +print FH "#mod_ssl has a problem with /dev/null\n";
  +close FH;
  +
   cp "t/conf/httpd.conf-dist", "t/conf/httpd.conf";
   chmod 0644, "t/conf/httpd.conf";
   
  
  
  
  1.32  +8 -5  modperl/t/conf/httpd.conf-dist
  
  Index: httpd.conf-dist
  ===
  RCS file: /home/cvs/modperl/t/conf/httpd.conf-dist,v
  retrieving revision 1.31
  retrieving revision 1.32
  diff -u -r1.31 -r1.32
  --- httpd.conf-dist   2000/03/30 19:59:17 1.31
  +++ httpd.conf-dist   2000/09/26 16:55:41 1.32
  @@ -180,11 +180,9 @@
   
   ErrorLog logs/error_log
   PidFile logs/httpd.pid
  -AccessConfig /dev/null
   ResourceConfig conf/srm.conf
  -TypesConfig /dev/null
  -TransferLog /dev/null
  -ScoreBoardFile /dev/null
  +#mod_ssl has a problem with /dev/null
  +TypesConfig conf/dev-null
   
   AddType text/x-server-parsed-html .shtml
   AddType text/html .html
  @@ -274,8 +272,13 @@
   /IfModule
   
   IfModule mod_ssl.c
  -SSLDisable
  +SSLEngine Off
   SSLSessionCache none
  +
  +SSLRandomSeed startup builtin
  +SSLRandomSeed connect builtin
  +#SSLLog  logs/ssl_engine_log
  +#SSLLogLevel info
   /IfModule
   
   Location /status
  
  
  



cvs commit: modperl/eg makepl_args.mod_perl

2000-09-26 Thread dougm

dougm   00/09/26 10:03:06

  Modified:.Changes
   eg   makepl_args.mod_perl
  Log:
  eg/makepl_args.mod_perl updated
  
  Revision  ChangesPath
  1.519 +3 -0  modperl/Changes
  
  Index: Changes
  ===
  RCS file: /home/cvs/modperl/Changes,v
  retrieving revision 1.518
  retrieving revision 1.519
  diff -u -r1.518 -r1.519
  --- Changes   2000/09/26 16:55:35 1.518
  +++ Changes   2000/09/26 17:02:59 1.519
  @@ -10,6 +10,9 @@
   
   =item 1.24_01-dev
   
  +eg/makepl_args.mod_perl updated
  +[Neil Conway [EMAIL PROTECTED]]
  +
   'make test' config fixes for mod_ssl
   [David Mitchell [EMAIL PROTECTED], Mark Murphy [EMAIL PROTECTED],
   Stephen Schaefer [EMAIL PROTECTED]]
  
  
  
  1.8   +4 -3  modperl/eg/makepl_args.mod_perl
  
  Index: makepl_args.mod_perl
  ===
  RCS file: /home/cvs/modperl/eg/makepl_args.mod_perl,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- makepl_args.mod_perl  1998/11/13 10:35:23 1.7
  +++ makepl_args.mod_perl  2000/09/26 17:03:05 1.8
  @@ -5,15 +5,16 @@
   #to the mod_perl-x.xx source tree
   
   #EVERYTHING=1 will enable:
  -#ALL_HOOKS=1 PERL_SSI=1 PERL_SECTIONS=1
  -#PERL_STACKED_HANDLERS=1 PERL_METHOD_HANDLERS=1 PERL_TABLE_API=1
  +#ALL_HOOKS=1 PERL_SSI=1 PERL_SECTIONS=1 PERL_STACKED_HANDLERS=1 
  +#PERL_METHOD_HANDLERS=1 PERL_TABLE_API=1 PERL_DIRECTIVE_HANDLERS=1
  +#PERL_LOG_API=1 PERL_URI_API=1 PERL_UTIL_API=1 PERL_FILE_API=1
   
   EVERYTHING=1
   
   #build against the first apache_x.xx source tree found, without prompts
   # DO_HTTPD=1
   
  -#could tell Makfile.PL exactly where the source is
  +#tell Makefile.PL exactly where the Apache source tree is
   # APACHE_SRC=/tmp/apache_x.xx/src
   
   #this would configure in mod_proxy, mod_unique_id, mod_info and mod_status
  
  
  



cvs commit: modperl Changes

2000-09-26 Thread dougm

dougm   00/09/26 11:42:02

  Modified:.Changes
  Log:
  fix bug in Perl{Set,Add}Var so $r-dir_config-get('key') sees the
  same values as $r-dir_config('key')
  
  Revision  ChangesPath
  1.522 +3 -0  modperl/Changes
  
  Index: Changes
  ===
  RCS file: /home/cvs/modperl/Changes,v
  retrieving revision 1.521
  retrieving revision 1.522
  diff -u -r1.521 -r1.522
  --- Changes   2000/09/26 18:20:45 1.521
  +++ Changes   2000/09/26 18:42:02 1.522
  @@ -10,6 +10,9 @@
   
   =item 1.24_01-dev
   
  +fix bug in Perl{Set,Add}Var so $r-dir_config-get('key') sees the
  +same values as $r-dir_config('key'), thanks to Geoffrey Young for the spot
  +
   PerlAddVar is now an ITERATE2 directive rather than TAKE2
   
   added Apache::Server::error_fname method
  
  
  



mod_perl test report

2000-09-26 Thread Richard Anderson

mod_perl VERSION: 1.24
Apache version: 1.3.12
Apache MMN: 19990320

make[1]: Entering directory `/exp/h1/staff/randerson/src/mod_perl-1.24'
(cd ../apache_1.3.12/src   make CC="cc";)
make[2]: Entering directory `/exp/h1/staff/randerson/src/apache_1.3.12/src'
=== regex
/exp/h1/staff/randerson/src/apache_1.3.12/src/regex
make[3]: Nothing to be done for `all'.
=== regex
=== os/unix
/exp/h1/staff/randerson/src/apache_1.3.12/src/os/unix
make[3]: Nothing to be done for `all'.
=== os/unix
=== ap
/exp/h1/staff/randerson/src/apache_1.3.12/src/ap
make[3]: Nothing to be done for `all'.
=== ap
=== main
/exp/h1/staff/randerson/src/apache_1.3.12/src/main
make[3]: Nothing to be done for `all'.
=== main
=== lib
/exp/h1/staff/randerson/src/apache_1.3.12/src/lib
=== lib/expat-lite
/exp/h1/staff/randerson/src/apache_1.3.12/src/lib/expat-lite
make[4]: Nothing to be done for `all'.
=== lib/expat-lite
=== lib
=== modules
/exp/h1/staff/randerson/src/apache_1.3.12/src/modules
=== modules/standard
/exp/h1/staff/randerson/src/apache_1.3.12/src/modules/standard
make[4]: Nothing to be done for `all'.
=== modules/standard
=== modules/perl
/exp/h1/staff/randerson/src/apache_1.3.12/src/modules/perl
make[4]: Nothing to be done for `all'.
=== modules/perl
=== modules
cc -c  -I./os/unix -I./include   -DLINUX=2 -DUSE_HSREGEX -DUSE_EXPAT 
-I./lib/expat-lite -DNO_DL_NEEDED -DMOD_PERL modules.c
cc -c  -I./os/unix -I./include   -DLINUX=2 -DUSE_HSREGEX -DUSE_EXPAT 
-I./lib/expat-lite -DNO_DL_NEEDED -DMOD_PERL buildmark.c
cc  -DLINUX=2 -DUSE_HSREGEX -DUSE_EXPAT -I./lib/expat-lite -DNO_DL_NEEDED -DMOD_PERL   
 \
  -o httpd buildmark.o modules.o modules/perl/libperl.a 
modules/standard/libstandard.a main/libmain.a ./os/unix/libos.a ap/libap.a 
regex/libregex.a lib/expat-lite/libexpat.a `perl 
/exp/h1/staff/randerson/src/mod_perl-1.24/src/modules/perl/ldopts  ` -lm -lcrypt
make[2]: Leaving directory `/exp/h1/staff/randerson/src/apache_1.3.12/src'
/exp/h1/staff/randerson/src/mod_perl-1.24/Apache
make[2]: Entering directory `/exp/h1/staff/randerson/src/mod_perl-1.24/Apache'
make[2]: Leaving directory `/exp/h1/staff/randerson/src/mod_perl-1.24/Apache'
/exp/h1/staff/randerson/src/mod_perl-1.24/Connection
make[2]: Entering directory `/exp/h1/staff/randerson/src/mod_perl-1.24/Connection'
make[2]: Leaving directory `/exp/h1/staff/randerson/src/mod_perl-1.24/Connection'
/exp/h1/staff/randerson/src/mod_perl-1.24/Constants
make[2]: Entering directory `/exp/h1/staff/randerson/src/mod_perl-1.24/Constants'
make[2]: Leaving directory `/exp/h1/staff/randerson/src/mod_perl-1.24/Constants'
/exp/h1/staff/randerson/src/mod_perl-1.24/File
make[2]: Entering directory `/exp/h1/staff/randerson/src/mod_perl-1.24/File'
make[2]: Leaving directory `/exp/h1/staff/randerson/src/mod_perl-1.24/File'
/exp/h1/staff/randerson/src/mod_perl-1.24/Leak
make[2]: Entering directory `/exp/h1/staff/randerson/src/mod_perl-1.24/Leak'
make[2]: Leaving directory `/exp/h1/staff/randerson/src/mod_perl-1.24/Leak'
/exp/h1/staff/randerson/src/mod_perl-1.24/Log
make[2]: Entering directory `/exp/h1/staff/randerson/src/mod_perl-1.24/Log'
make[2]: Leaving directory `/exp/h1/staff/randerson/src/mod_perl-1.24/Log'
/exp/h1/staff/randerson/src/mod_perl-1.24/ModuleConfig
make[2]: Entering directory `/exp/h1/staff/randerson/src/mod_perl-1.24/ModuleConfig'
make[2]: Leaving directory `/exp/h1/staff/randerson/src/mod_perl-1.24/ModuleConfig'
/exp/h1/staff/randerson/src/mod_perl-1.24/PerlRunXS
make[2]: Entering directory `/exp/h1/staff/randerson/src/mod_perl-1.24/PerlRunXS'
make[2]: Leaving directory `/exp/h1/staff/randerson/src/mod_perl-1.24/PerlRunXS'
/exp/h1/staff/randerson/src/mod_perl-1.24/Server
make[2]: Entering directory `/exp/h1/staff/randerson/src/mod_perl-1.24/Server'
make[2]: Leaving directory `/exp/h1/staff/randerson/src/mod_perl-1.24/Server'
/exp/h1/staff/randerson/src/mod_perl-1.24/Symbol
make[2]: Entering directory `/exp/h1/staff/randerson/src/mod_perl-1.24/Symbol'
make[2]: Leaving directory `/exp/h1/staff/randerson/src/mod_perl-1.24/Symbol'
/exp/h1/staff/randerson/src/mod_perl-1.24/Table
make[2]: Entering directory `/exp/h1/staff/randerson/src/mod_perl-1.24/Table'
make[2]: Leaving directory `/exp/h1/staff/randerson/src/mod_perl-1.24/Table'
/exp/h1/staff/randerson/src/mod_perl-1.24/URI
make[2]: Entering directory `/exp/h1/staff/randerson/src/mod_perl-1.24/URI'
make[2]: Leaving directory `/exp/h1/staff/randerson/src/mod_perl-1.24/URI'
/exp/h1/staff/randerson/src/mod_perl-1.24/Util
make[2]: Entering directory `/exp/h1/staff/randerson/src/mod_perl-1.24/Util'
make[2]: Leaving directory `/exp/h1/staff/randerson/src/mod_perl-1.24/Util'
/exp/h1/staff/randerson/src/mod_perl-1.24/t/conf
/exp/h1/staff/randerson/src/mod_perl-1.24/t/net
../apache_1.3.12/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
/usr/bin/perl t/TEST 0
modules/actions.ok
modules/cgi.ok
modules/constants...ok

cvs commit: modperl/src/modules/perl perl_config.c

2000-09-26 Thread dougm

dougm   00/09/26 13:07:36

  Modified:src/modules/perl perl_config.c
  Log:
  fix bug in Perl{Set,Add}Var so $r-dir_config-get('key') sees the
  same values as $r-dir_config('key')
  
  Revision  ChangesPath
  1.103 +10 -8 modperl/src/modules/perl/perl_config.c
  
  Index: perl_config.c
  ===
  RCS file: /home/cvs/modperl/src/modules/perl/perl_config.c,v
  retrieving revision 1.102
  retrieving revision 1.103
  diff -u -r1.102 -r1.103
  --- perl_config.c 2000/09/22 18:52:00 1.102
  +++ perl_config.c 2000/09/26 20:05:22 1.103
  @@ -717,17 +717,18 @@
   
   CHAR_P perl_cmd_var(cmd_parms *cmd, void *config, char *key, char *val)
   {
  +perl_dir_config *rec = (perl_dir_config *)config;
  +
   MP_TRACE_d(fprintf(stderr, "perl_cmd_var: '%s' = '%s'\n", key, val));
  -if (cmd-path) {
  -perl_dir_config *rec = (perl_dir_config *) config;
  -if (cmd-info) {
  -table_add(rec-vars, key, val);
  -}
  -else {
  -table_set(rec-vars, key, val);
  -}
  +
  +if (cmd-info) {
  +table_add(rec-vars, key, val);
   }
   else {
  +table_set(rec-vars, key, val);
  +}
  +
  +if (cmd-path == NULL) {
   dPSRV(cmd-server);
   if (cmd-info) {
   table_add(cls-vars, key, val);
  @@ -736,6 +737,7 @@
   table_set(cls-vars, key, val);
   }
   }
  +
   return NULL;
   }
   
  
  
  



cvs commit: modperl/lib/Apache src.pm

2000-09-26 Thread dougm

dougm   00/09/26 13:20:00

  Modified:.Changes
   apacimod_perl.config.sh
   lib/Apache src.pm
  Log:
  static+apaci fixes for aix
  
  Revision  ChangesPath
  1.523 +2 -0  modperl/Changes
  
  Index: Changes
  ===
  RCS file: /home/cvs/modperl/Changes,v
  retrieving revision 1.522
  retrieving revision 1.523
  diff -u -r1.522 -r1.523
  --- Changes   2000/09/26 18:42:02 1.522
  +++ Changes   2000/09/26 20:11:03 1.523
  @@ -10,6 +10,8 @@
   
   =item 1.24_01-dev
   
  +static+apaci fixes for aix [Jens-Uwe Mager [EMAIL PROTECTED]]
  +
   fix bug in Perl{Set,Add}Var so $r-dir_config-get('key') sees the
   same values as $r-dir_config('key'), thanks to Geoffrey Young for the spot
   
  
  
  
  1.19  +7 -0  modperl/apaci/mod_perl.config.sh
  
  Index: mod_perl.config.sh
  ===
  RCS file: /home/cvs/modperl/apaci/mod_perl.config.sh,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -r1.18 -r1.19
  --- mod_perl.config.sh2000/03/31 05:16:05 1.18
  +++ mod_perl.config.sh2000/09/26 20:15:06 1.19
  @@ -147,6 +147,13 @@
   print $ldopts;
   EOT
   perl_libs="`$perl_interp $tmpfile2 $perl_libperl`"
  +if test $build_type = OBJ
  +then
  + case "$os_version" in
  + aix*)  perl_libs="$perl_libs -bE:\$(SRCDIR)/modules/perl/mod_perl.exp" ;;
  + * );;
  + esac
  +fi
   perl_inc="`$perl_interp -MConfig -e 'print "$Config{archlibexp}/CORE"'`"
   perl_privlibexp="`$perl_interp -MConfig -e 'print $Config{privlibexp}'`"
   perl_archlibexp="`$perl_interp -MConfig -e 'print $Config{archlibexp}'`"
  
  
  
  1.27  +6 -1  modperl/lib/Apache/src.pm
  
  Index: src.pm
  ===
  RCS file: /home/cvs/modperl/lib/Apache/src.pm,v
  retrieving revision 1.26
  retrieving revision 1.27
  diff -u -r1.26 -r1.27
  --- src.pm2000/06/05 18:16:33 1.26
  +++ src.pm2000/09/26 20:16:52 1.27
  @@ -258,7 +258,12 @@
push @ldflags, "-bI:" . $file;
}
my $httpdexp = $self-apxs("-q" = 'LIBEXECDIR') . "/httpd.exp";
  - push @ldflags, "-bI:$httpdexp" if -e $httpdexp;
  + if (-e $httpdexp) {
  + push @ldflags, "-bI:$httpdexp";
  + } else {
  + $httpdexp = $self-dir . "/support/httpd.exp";
  + push @ldflags, "-bI:$httpdexp" if -e $httpdexp;
  + }
   }
   return join(' ', @ldflags);
   }
  
  
  



cvs commit: modperl/src/modules/perl perl_config.c

2000-09-26 Thread dougm

dougm   00/09/26 14:02:44

  Modified:.Changes
   src/modules/perl perl_config.c
  Log:
  fix for Perl{Module,Require} in .htaccess
  
  Revision  ChangesPath
  1.524 +3 -0  modperl/Changes
  
  Index: Changes
  ===
  RCS file: /home/cvs/modperl/Changes,v
  retrieving revision 1.523
  retrieving revision 1.524
  diff -u -r1.523 -r1.524
  --- Changes   2000/09/26 20:11:03 1.523
  +++ Changes   2000/09/26 21:02:36 1.524
  @@ -10,6 +10,9 @@
   
   =item 1.24_01-dev
   
  +fix for Perl{Module,Require} in .htaccess,
  +thanks to Will Trillich and Andrew Gideon for the spot
  +
   static+apaci fixes for aix [Jens-Uwe Mager [EMAIL PROTECTED]]
   
   fix bug in Perl{Set,Add}Var so $r-dir_config-get('key') sees the
  
  
  
  1.104 +7 -2  modperl/src/modules/perl/perl_config.c
  
  Index: perl_config.c
  ===
  RCS file: /home/cvs/modperl/src/modules/perl/perl_config.c,v
  retrieving revision 1.103
  retrieving revision 1.104
  diff -u -r1.103 -r1.104
  --- perl_config.c 2000/09/26 20:05:22 1.103
  +++ perl_config.c 2000/09/26 21:02:42 1.104
  @@ -587,8 +587,11 @@
return NULL;
}
   }
  -*(char **)push_array(cls-PerlModule) = pstrdup(parms-pool, arg);
   
  +if (cld-PerlModule) {
  +*(char **)push_array(cls-PerlModule) = pstrdup(parms-pool, arg);
  +}
  +
   #ifdef PERL_SECTIONS
   if(CAN_SELF_BOOT_SECTIONS)
perl_section_self_boot(parms, dummy, arg);
  @@ -618,7 +621,9 @@
}
   }
   
  -*(char **)push_array(cls-PerlRequire) = pstrdup(parms-pool, arg);
  +if (cls-PerlRequire) {
  +*(char **)push_array(cls-PerlRequire) = pstrdup(parms-pool, arg);
  +}
   
   #ifdef PERL_SECTIONS
   if(CAN_SELF_BOOT_SECTIONS)
  
  
  



cvs commit: modperl-site/embperl CVS.pod.1.html Changes.pod.1.html

2000-09-26 Thread richter

richter 00/09/26 21:37:58

  Modified:embperl  CVS.pod.1.html Changes.pod.1.html
  Log:
  Embperl Webpages - Changes
  
  Revision  ChangesPath
  1.13  +1 -1  modperl-site/embperl/CVS.pod.1.html
  
  Index: CVS.pod.1.html
  ===
  RCS file: /home/cvs/modperl-site/embperl/CVS.pod.1.html,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- CVS.pod.1.html2000/08/25 05:31:38 1.12
  +++ CVS.pod.1.html2000/09/27 04:37:57 1.13
  @@ -162,7 +162,7 @@
   P
   There is a CVS mailing list for Embperl (This is CVS - STRONGnot/STRONG a list 
for asking questions about Embperl!!!). This list receives all
   changes which are commited to the CVS. If you want to know what's going on
  -which Embperl, you can subscribe by sending a mail to 
STRONG[EMAIL PROTECTED]/STRONG
  +which Embperl, you can subscribe by sending a mail to 
STRONG[EMAIL PROTECTED]/STRONG
   with STRONGsubscribe/STRONG in the body.
   
   p[a href="" HOME/a]nbsp;nbsp; [a 
href="CVS.pod.cont.html"CONTENT/a]nbsp;nbsp; [a href="CVS.pod.cont.html"PREV 
(CVS - Content)/a]nbsp;nbsp; br
  
  
  
  1.175 +1 -1  modperl-site/embperl/Changes.pod.1.html
  
  Index: Changes.pod.1.html
  ===
  RCS file: /home/cvs/modperl-site/embperl/Changes.pod.1.html,v
  retrieving revision 1.174
  retrieving revision 1.175
  diff -u -r1.174 -r1.175
  --- Changes.pod.1.html2000/09/11 09:54:12 1.174
  +++ Changes.pod.1.html2000/09/27 04:37:58 1.175
  @@ -21,7 +21,7 @@
   
   [a href="" HOME/a]nbsp;nbsp; [a 
href="Changes.pod.cont.html"CONTENT/a]nbsp;nbsp; [a 
href="Changes.pod.cont.html"PREV (Revision History - Content)/a]nbsp;nbsp; [a 
href="Changes.pod.2.html"NEXT (1.3b5 (BETA)  20. Aug 2000)/a]nbsp;nbsp; brhr
   P
  -Last Update: Mon Sep 11 11:54:52 2000 (MET)
  +Last Update: Wed Sep 27 06:38:46 2000 (MET)
   
   P
   NOTE: This version is only available via A HREF="CVS.pod.1.html#INTRO" "CVS"/A