Return-Path: Delivered-To: apmail-perl-modperl-archive@www.apache.org Received: (qmail 59059 invoked from network); 5 May 2006 20:15:34 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 5 May 2006 20:15:34 -0000 Received: (qmail 22480 invoked by uid 500); 5 May 2006 20:15:27 -0000 Delivered-To: apmail-perl-modperl-archive@perl.apache.org Received: (qmail 22459 invoked by uid 500); 5 May 2006 20:15:27 -0000 Mailing-List: contact modperl-help@perl.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: List-Id: Delivered-To: mailing list modperl@perl.apache.org Received: (qmail 22448 invoked by uid 99); 5 May 2006 20:15:27 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 05 May 2006 13:15:27 -0700 X-ASF-Spam-Status: No, hits=1.4 required=10.0 tests=DNS_FROM_RFC_ABUSE,DNS_FROM_RFC_WHOIS X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: local policy) Received: from [68.142.200.168] (HELO web31005.mail.mud.yahoo.com) (68.142.200.168) by apache.org (qpsmtpd/0.29) with SMTP; Fri, 05 May 2006 13:15:26 -0700 Received: (qmail 45017 invoked by uid 60001); 5 May 2006 20:15:05 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=Message-ID:Received:Date:From:Subject:To:In-Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=Ucu5p1Nh7Ve4kp4e0SS3KFMc3PthOW7244gNk0ryHipKpI7pxAuKmGD7PjVtLvpLUXAV60Kpz87qzW3vEYtdEGR65B0Cl5Lsn7i4LTzwHBREV+MHZoeYJo040PD7va8/EQId+F0l2jkJFcO6ZpWKE2tmFi7szLB/I1k8RHmRwLU= ; Message-ID: <20060505201505.45013.qmail@web31005.mail.mud.yahoo.com> Received: from [70.50.234.199] by web31005.mail.mud.yahoo.com via HTTP; Fri, 05 May 2006 13:15:05 PDT Date: Fri, 5 May 2006 13:15:05 -0700 (PDT) From: Thomas Hilbig Subject: Re: Reinstall gets Can't locate Apache.pm To: mod_perl list In-Reply-To: <20060505193531.GF26237@yi.org> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N --- Tyler MacDonald wrote: > Thomas Hilbig wrote: > > I was getting the error even from running perl > > interactively > > linux>perl > > use CGI ; > > Can't locate Apache.pm in @INC > > > > I think the problem may be that I am simply > missing > > the MOD_PERL_API_VERSION environment variable in > my > > shell environment. I had MOD_PERL set in my shell > > environment (from when??), but not the other. > > > > Hopefully, I haven't butchered my Perl install > beyond > > repair. > > Weird! Are you running the latest version of CGI? > If not, that could > be the problem, CGI had to be updated to support > mod_perl2. > > Cheers, > Tyler > Originally I was using CGI 3.16, but the 3.20 has the same check: if (exists $ENV{MOD_PERL}) { # mod_perl handlers may run system() on scripts using CGI.pm; # Make sure so we don't get fooled by inherited $ENV{MOD_PERL} if (exists $ENV{MOD_PERL_API_VERSION} && $ENV{MOD_PERL_API_VERSION} == 2) { $MOD_PERL = 2; require Apache2::Response; require Apache2::RequestRec; require Apache2::RequestUtil; require Apache2::RequestIO; require APR::Pool; } else { $MOD_PERL = 1; require Apache; } } Having the MOD_PERL environment but not having MOD_PERL_API_VERSION causes grief. However, the instructions do say it is required so it's my fault for not catching it earlier. Tom __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com