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