Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the PDL CPAN distribution.

Report information
The Basics
Id: 30276
Status: resolved
Priority: 0/
Queue: PDL

People
Owner: Nobody in particular
Requestors: twc [...] aaocbn.aao.gov.au
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: 2.4.3
Fixed in: 2.4.4



Subject: Makefile.PL WITH_3D autodetection fails to find xdpyinfo with some $PATHs
Date: Fri, 26 Oct 2007 17:12:29 +1000 (EST)
To: bug-PDL [...] rt.cpan.org
From: Tim Connors <twc [...] aaocbn.aao.gov.au>
In Makefile.PL, WITH_3D tests for xdpyinfo using File::Find::find(), which doesn't resolve symlinks by default. With a path containing /usr/bin/X11 on a system where that is a symlink to ../X11R6/bin means that xdpyinfo doesn't get found, because the $have_xdpyinfo_command just supplies the symlink name to find, which does nothing with it without the follow option being set. You could set the "follow" option, but I don't know whether that will cause problems with recursive directory structures (I think you are only going one deep anyway, so it shouldn't). I solved it by adding a trailing slash to each directory name: && ++$have_xdpyinfo_command && print "."; }, map { "$_/" } (split ':', $ENV{PATH}) ); -- Tim Connors | Anglo-Australian Observatory http://site.aao.gov.au/twc | Coonabarabran, NSW 2357, Australia | Tel: +61 2 6842 6286
RT-Send-CC: pdl-porters [...] jach.hawaii.edu
On Fri Oct 26 03:13:54 2007, twc@aaocbn.aao.gov.au wrote: Show quoted text
> > In Makefile.PL, WITH_3D tests for xdpyinfo using > File::Find::find(), which doesn't resolve symlinks by > default. > > With a path containing /usr/bin/X11 on a system where > that is a symlink to ../X11R6/bin means that xdpyinfo > doesn't get found, because the $have_xdpyinfo_command just > supplies the symlink name to find, which does nothing with > it without the follow option being set. > > You could set the "follow" option, but I don't know > whether that will cause problems with recursive directory > structures (I think you are only going one deep anyway, so > it shouldn't). I solved it by adding a trailing slash to > each directory name: > > && ++$have_xdpyinfo_command && print "."; }, > map { "$_/" } (split ':', > $ENV{PATH}) );
Thanks for the feedback. The xdpyinfo "test" was an effort to improve the auto-probe capabilities of the PDL OpenGL install as well as the diagnostics. You fix seems good to me but there may be path separator issues with win32 or cygwin. I see that you have signed up for the PDL mailing lists which is probably the best way to communicate with the PDL users and developers. There are issues with the CPAN RT tracking system regarding permissions that prevent effective coordination with the general PDL developers lists: (1) bug reports do not get reflected to pdl-porters (2) there is no one with admin permissions on the RT system who is currently active in monitoring PDL tickets and problem reports. Thanks again, Chris
Subject: Re: [rt.cpan.org #30276] Makefile.PL WITH_3D autodetection fails to find xdpyinfo with some $PATHs
Date: Wed, 12 Dec 2007 13:32:23 +1100 (EST)
To: Chris Marshall via RT <bug-PDL [...] rt.cpan.org>
From: Tim Connors <twc [...] aaocbn.aao.gov.au>
On Mon, 5 Nov 2007, Chris Marshall via RT wrote: Show quoted text
> > <URL: http://rt.cpan.org/Ticket/Display.html?id=30276 > > > On Fri Oct 26 03:13:54 2007, twc@aaocbn.aao.gov.au wrote:
> > > > In Makefile.PL, WITH_3D tests for xdpyinfo using > > File::Find::find(), which doesn't resolve symlinks by > > default. > > > > With a path containing /usr/bin/X11 on a system where > > that is a symlink to ../X11R6/bin means that xdpyinfo > > doesn't get found, because the $have_xdpyinfo_command just > > supplies the symlink name to find, which does nothing with > > it without the follow option being set. > > > > You could set the "follow" option, but I don't know > > whether that will cause problems with recursive directory > > structures (I think you are only going one deep anyway, so > > it shouldn't). I solved it by adding a trailing slash to > > each directory name: > > > > && ++$have_xdpyinfo_command && print "."; }, > > map { "$_/" } (split ':', > $ENV{PATH}) );
> > Thanks for the feedback. The xdpyinfo "test" was an > effort to improve the auto-probe capabilities of the > PDL OpenGL install as well as the diagnostics. You fix > seems good to me but there may be path separator issues > with win32 or cygwin.
Another theoretical problem is I believe that find could hit false positives if PATH contains /foo/bin and there is a filename called /foo/bin/bar/xdpyinfo I may have fixed both problems with a call to: find({ follow_fast => 1, follow_skip => 2, wanted => sub { -f && /^xdpyinfo(.exe)?$/i && ++$have_xdpyinfo_command && print "."; $File::Find::prune = 1 if tr!/\\!! ; print "$File::Find::name\n"; } }, (split ':', $ENV{PATH})); A lot more ugly than previously, but seems to work :) Haven't tested on windows, but the tr command there is just counting the number of slashes (of either windows or unix variety) in the filename after the path supplied. -- Tim Connors | Anglo-Australian Observatory http://site.aao.gov.au/twc | Coonabarabran, NSW 2357, Australia | Tel: +61 2 6842 6286
See http://sourceforge.net/tracker/?func=browse&group_id=612&atid=100612 bug # 1994614 for follow up and resolution.
The proposed fix has been merged into PDL cvs for the upcoming PDL-2.4.4 release. Thanks. Please follow up with any additional issues to the bug tracker on the sourceforge.net PDL project page or via the perldl mailing list.