This is the mail archive of the
cygwin@cygwin.com
mailing list for the Cygwin project.
Perl package File::Spec confused under cygwin
- From: "linda w \(cyg\)" <cygwin at tlinx dot org>
- To: <cygwin at cygwin dot com>
- Date: Fri, 20 Dec 2002 13:27:50 -0800
- Subject: Perl package File::Spec confused under cygwin
File::Spec is supposed to provide a OS independent way of parsing and
creating pathnames. For example, a 'splitpath' can product a volume
$dir and $file.
I'm not sure what constitutes a volume but I'd think C: D: would count
as separate.
Under cygwin, it only handles/parses unix pathnames but not native
windows pathnames 'c:\windows\filename' will yield a vol='', dir='' and
filename='d:\windows\filelname' -- not what one would expect. Using
forward slashes yields: vdf='', 'd:/windows/,'filename'.
Further use to break down the directory path into components would
yield D: as a first directory and 'windows' as a 2nd level dir.
Note that the forward slash has now disappeared indicating what I believe
to be improper symantics as d:windows != D:\windows unless d:'s curdir
is = to the root dir.
Guess when the module detects the OS type, it needs to have a separate
type for the cygwin environment.
-linda
--
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/