ryddler has asked for the wisdom of the Perl Monks concerning the following question:
In reviewing some software I ran across the requirement in one software package for Apache::Request, so I did the good ol' cpan install for libapreq (or rather attempted the cpan install) without any success (on win32).
Not to be dissuaded so easily I downloaded the package from cpan and did a manual install. Nothing flashed by onscreen during 'nmake'. There appeared to be no tests defined, so 'nmake install' showed activity of copying .pm files to the appropriate locations, and navigating to those directories showed modules were in fact located where they should be located.
Ok, wonderful, all looks good, so I add the 'include' line into httpd.conf and attempt to stop and start apache, but apache squawks "Can't locate loadable object for module Apache::Request in @INC ... "
Further investigation reveals no binaries in the site/lib/auto/apache/request directory, although there is indeed c code in the install package, as well as code in Makefile.pl to distinguish between win32 and other os types for creating the makefile. Maybe a win32 problem? So next I tried it on a RH 7.1 box with a fresh build of perl 5.6.1 on it. Same process, CPAN first this time with a successful build and compiler instructions racing by on the screen. I verified that there was indeed a file named "Request.so" in the auto subdir, and ran this test script:
#! /usr/bin/perl use CGI qw(:standard); use CGI::Carp qw(fatalsToBrowser); use Apache::Request; use Data::Dumper; print header; print "hello world<br>"; my $r; eval {$r = Apache::Request->new();}; print "$@ <br>"; print Dumper($r); map { print "$_<br>" } @INC;
Which spits out the following:
hello world Can't locate object method "new" via package "Apache::Request" (perhaps you forgot to load "Apache::Request"?) at /usr/local/apache/cgi-bin/testapache.pl line 13. $VAR1 = undef; /usr/local/lib/perl5/5.6.1/i586-linux /usr/local/lib/perl5/5.6.1 /usr/local/lib/perl5/site_perl/5.6.1/i586-linux /usr/local/lib/perl5/site_perl/5.6.1 /usr/local/lib/perl5/site_perl
So my questions are:
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Apache::Request, myth or reality?
by echo (Pilgrim) on Sep 17, 2001 at 20:25 UTC | |
Re: Apache::Request, myth or reality?
by perrin (Chancellor) on Sep 17, 2001 at 20:48 UTC | |
by ryddler (Monk) on Sep 19, 2001 at 01:57 UTC | |
by perrin (Chancellor) on Sep 19, 2001 at 03:47 UTC | |
by Anonymous Monk on May 01, 2003 at 17:24 UTC |