This is the mail archive of the cygwin mailing list for the Cygwin project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Bug with paths containing double slashes after double dot after a mount point


 I think I've discovered a bug with handling specific forms of "mixed" form
paths in Cygwin 1.7. Here is the briefest possible demonstration:

	$ ls C:/cygwin/lib/X11/../libc.a
	$ ls C:/cygwin/lib/X11/..//libc.a
	ls: cannot access C:/cygwin/lib/X11/..//libc.a: No such file or directory

This is on a system with perfectly standard Cygwin installation and
standard /usr/lib mount:

	$ mount|fgrep lib
	C:/cygwin/lib on /usr/lib type ntfs (binary,auto)

The bug is not specific to this machine (at least it also happens in a
freshly created VM with a very minimal Cygwin 1.7 installation too) nor to
this mount point (I originally noticed it with one of my own manually
created ones). Neither is it specific to the concrete file or directory

 The problem does *not* arise with /cygdrive/c/cygwin/lib/X11/..//libc.a
Unix-style paths but unfortunately I can't easily get rid of the mixed
format paths in my situation: the original path comes from "g++
-print-search-dirs" output from MinGW g++ that I use from Cygwin
environment and I can't even apply cygpath to convert it because this is
all done by libtool. And because the directory containing the libraries has
a trailing slash in g++ output libtool fails to create any libraries in it
resulting in various interesting problems... So while the real solution
would probably be to switch to MinGW cross-compiler and avoid mixing of
MinGW and Cygwin paths in the first place, for now I'd gladly welcome any
ideas about how to work around this bug.

 Thanks in advance,

P.S. I don't include detailed cygcheck output as I don't think it's of any
     interest because the bug isn't system-dependent but please let me know
     if it would be useful to send it nevertheless, e.g. if you can't
     reproduce this behaviour.

Attachment: pgp00000.pgp
Description: PGP signature

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]