Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Date: Sat, 28 Dec 2002 02:46:04 +0100 From: "Gerrit P. Haase" Reply-To: "Gerrit P. Haase" Organization: Esse keine toten Tiere X-Priority: 3 (Normal) Message-ID: <1191230845802.20021228024604@familiehaase.de> To: Igor Pechtchanski Subject: Re: perl 5.8.1: perldoc perl fails In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Sender: 320081107336-0001 AT t-dialin DOT net Hallo Igor, Am Samstag, 28. Dezember 2002 um 02:10 schriebst du: > On Sat, 28 Dec 2002, Gerrit P. Haase wrote: >> Hallo Joerg, >> >> Am Freitag, 20. Dezember 2002 um 17:55 schriebst du: >> >> > Hi Perl maintainer, >> >> > using the new experimental Perl 5.8.1 release, the command >> >> > $ perldoc perl >> > Can't open /usr/bin/perl: No such file or directory at /bin/perldoc line >> > 206. >> >> perldoc perl.pod works well >> >> > fails to present the Perl manual overview. Calling the manual pages >> > directly, anything works well: >> >> > perldoc perlfun >> >> > It seems that perldoc does not find the /usr/lib/perl5/5.8.1/pods/perl.pod, >> > because it matches somehow /usr/bin/perl first. >> >> Yes, please fix it :-) >> >> I just figured that calling: perldoc perl.pod works well. >> I tried to understand what happens in the perldoc script >> and I have no idea why it doesn't work. And most >> interesting is that it works with perl 5.6.1. >> >> Gerrit > Gerrit, > I'm by no means a perl guru, but here are a few observations from > /usr/bin/perldoc: > 266: sub searchfor { > 267: my($recurse,$s,@dirs) = @_; > 276: for ($i=0; $i<@dirs; $i++) { > 277: $dir = $dirs[$i]; > 279: if ( ( $ret = check_file $dir,"$s.pod") > 280: or ( $ret = check_file $dir,"$s.pm") > 281: or ( $ret = check_file $dir,$s) > ... etc ... > 312: } This should do it. > 400: foreach (@pages) { > 413: # We must look both in @INC for library modules and in $bindir > 414: # for executables, like h2xs or perldoc itself. > 415: my @searchdirs = (@INC, $bindir); > 434: my @files = searchfor(0,$_,@searchdirs); > 462: } This too. > In other words, it looks like the script searches @INC (which can vary > from version to version). If you look at the changes in @INC between > 5.6.1 and 5.8, you could probably track down this problem. It should find perl.pod in the @INC, but it doesn't, instead it looks in /bin and finds the executable. > Sorry if I'm restating the obvious. > Igor No problem, that was the same what I saw, I fiddled around at some lines and tried to change this and that, but it became worse and I decided to let it as it is until some nice guy comes up with a nice bug report which helps us to track it down :-) Gerrit -- =^..^= -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Bug reporting: http://cygwin.com/bugs.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/