delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2020/06/12/03:07:15

X-Recipient: archive-cygwin AT delorie DOT com
DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 265653953421
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cygwin.com;
s=default; t=1591945588;
bh=c0tVk+ExGkzCgb3scDXyiJJEtYnvz+wiXHX22P2DnfM=;
h=Date:To:Subject:List-Id:List-Unsubscribe:List-Archive:List-Post:
List-Help:List-Subscribe:From:Reply-To:From;
b=X8Yu1tubVy2Zll+uISsdXXxH8mCZizgdHJC6y2zRYrC51SGrzgciEulZ97qDzYkbf
WLr2k9E6KPsnM0KTE1Hk2rwVw0tJHDYHeHs1ZjH7ccw42fHkqIcNfN47tYOS7dFquG
NrmthBiKZPRYqxXSQ4qEaT4PtcIaOynza4nqFbJU=
X-Original-To: cygwin AT cygwin DOT com
Delivered-To: cygwin AT cygwin DOT com
DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org D38963952DB2
X-Cam-AntiVirus: no malware found
X-Cam-ScannerInfo: http://help.uis.cam.ac.uk/email-scanner-virus
Date: Fri, 12 Jun 2020 08:06:24 +0100 (GMT Summer Time)
To: cygwin AT cygwin DOT com
Subject: symbolic links to /cygdrive/X/xxx with capital letter X
Message-ID: <alpine.WNT.2.00.2006120735160.21688@panamint>
User-Agent: Alpine 2.00 (WNT 1167 2008-08-23)
X-X-Sender: acn1 AT imap DOT hermes DOT cam DOT ac DOT uk
MIME-Version: 1.0
X-Spam-Status: No, score=-1.6 required=5.0 tests=BAYES_00, DKIMWL_WL_MED,
DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, RCVD_IN_MSPIKE_H3,
RCVD_IN_MSPIKE_WL, SPF_HELO_PASS, SPF_PASS,
TXREP autolearn=ham autolearn_force=no version=3.4.2
X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on
server2.sourceware.org
X-BeenThere: cygwin AT cygwin DOT com
X-Mailman-Version: 2.1.29
List-Id: General Cygwin discussions and problem reports <cygwin.cygwin.com>
List-Archive: <https://cygwin.com/pipermail/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-request AT cygwin DOT com?subject=help>
List-Subscribe: <http://cygwin.com/mailman/listinfo/cygwin>,
<mailto:cygwin-request AT cygwin DOT com?subject=subscribe>
From: Arthur Norman via Cygwin <cygwin AT cygwin DOT com>
Reply-To: Arthur Norman <acn1 AT cam DOT ac DOT uk>
Sender: "Cygwin" <cygwin-bounces AT cygwin DOT com>

This running on Windows 10 1909 and cygwin has been updated to the latest 
version. The effect was also visible on a freshly installed minimal cygwin 
put on an almost fresh Windows 10 VM.

Cygwin these days seems to have a behaviour that confuses me regarding the 
case of a disk name:

> ln -s "/cygdrive/c/Program Files" pf1
> ln -s "/cygdrive/C/Program Files" pf2
> ls -l pf*
lrwxrwxrwx 1 acn1 None 25 Jun 12 07:37 pf1 -> /cygdrive/c/Program Files
lrwxrwxrwx 1 acn1 None 20 Jun 12 07:37 pf2 -> /mnt/C/Program Files
> cygpath -ma ./pf1
C:/cygwin64/home/acn1/pf1

You see from the above that when I use cygpath to convert from a cygwin 
name the drive letter C: is returned in upper case. When that ends up 
after "/cygdrive" the path behaves as I expect almost everywhere by is 
treated specially for symbolic links. This seems to be a relatively new 
behaviour and it bit me!

[Use-case: I wanted to convert cygwin paths to be "very absolute" so that 
eg my home directory is not rendered as /home/acn1 but as 
/cygdrive/c/cygwin64/home/acn1, so I had a few lines of shell script to 
achieve that. I was building a package and I build both a cygwin32 and a 
cygwin64 version, so the "very absolute" paths are portable between the 
two worlds, both of which were important when I first set this up. Things 
recently broke and on investigation it was because somewhere deep in 
build scripts links to /mnt/C/... had been set up and were not usable. I 
can of course work round the issue but being confident I have spotted all 
cases causes me work!]

Arthur

--
Problem reports:      https://cygwin.com/problems.html
FAQ:                  https://cygwin.com/faq/
Documentation:        https://cygwin.com/docs.html
Unsubscribe info:     https://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019