delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2020/11/25/03:03:06

X-Recipient: archive-cygwin AT delorie DOT com
DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 9EE353954801
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cygwin.com;
s=default; t=1606291337;
bh=vtMRVF0/Qc3P1+6RAYTvRu0375xwFOq5lengfJNkT+8=;
h=To:References:In-Reply-To:Subject:Date:List-Id:List-Unsubscribe:
List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:
From;
b=v/aiNSlkdmwM6nwCGVvqZWQDUxwuSMvXfrQ5Ed7cuHdKN5+pyiKYWj43itBsJLdXM
oslfhhhHRsBZ9/4INHMBCs9spJetJZ5MXNXOBXZrwJp8cdvfcCI9TWezm85lRgRYQM
BjOvWjvmzFw1/VjsErUrwKruYRMQ1fOiO6LX0X6A=
X-Original-To: cygwin AT cygwin DOT com
Delivered-To: cygwin AT cygwin DOT com
DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org DBE143857809
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=1e100.net; s=20161025;
h=x-gm-message-state:from:to:references:in-reply-to:subject:date
:message-id:mime-version:content-transfer-encoding:content-language
:thread-index;
bh=oM9XGo663RHqHbqpax7CSdUh3D15NmfiQHNeUsKSRyk=;
b=n05O69281QYx24kaJGhG/m9xzy0/fK740o8OYy7yF/+OYHaS5bQjbo3fDUQcCpdPa4
09yWGoUvKK+h0xNlo1eXimrwSTrBDLKV8dPD1Ky+cz+mjC3dSxbqNQPnAErLbgHX+IaM
MZ4sMvYXKjrTI/4njMn0hGIo1Bbjy0r3lOtUl1EA8oUK9TEyPrylEVo2ldnTgkRTZ88C
6jzRziKgPMKO8uycIXcSk/H+UXOesPSX18WLmsqmWaK7rSZn3QUbQ/yBkkta3ONPRCQ5
CCJdTx8kiJY0fm11nEKHoqPg8v/yB6R/twbj3XQ+51R7wChiAtEJEAyi0Tu0wFyVFv43
U6hg==
X-Gm-Message-State: AOAM53250j24dj8TFGqQN48VPUnI2g1qDgNJaa92f3bVOZG8wA6LwuEe
1ltSwtbZJmWLnbS771stJr4DR1J85U0=
X-Google-Smtp-Source: ABdhPJzOrkLQgxOkZTTYD8Dme5+mNtHtK3zxUTh7h8UhLTn96kBQdeub/EbaOIL3zLowu9n23MTHJA==
X-Received: by 2002:a19:c144:: with SMTP id r65mr772695lff.362.1606291332339;
Wed, 25 Nov 2020 00:02:12 -0800 (PST)
To: <moss AT cs DOT umass DOT edu>, "'The Cygwin Mailing List'" <cygwin AT cygwin DOT com>
References: <c2d6280c-26e3-f9e7-89bd-693385a768b2 AT gmail DOT com>
<D3704C33-A283-40F0-990D-CB9806F0B09D AT gmail DOT com>
<000a01d6be5b$3808cad0$a81a6070$@gmail.com>
<87a2c99c-045c-e815-4c03-bab7a89a025b AT cs DOT umass DOT edu>
<000201d6bf17$7cc4beb0$764e3c10$@gmail.com>
<9e881c01-e883-ecd5-883a-e1ac55c740c7 AT gmail DOT com>
<000601d6c173$aa55d540$ff017fc0$@gmail.com>
<d8a72610-a79b-0387-e52b-25f0b50c46ef AT gmail DOT com>
<000a01d6c244$b64bbd70$22e33850$@gmail.com>
<237eacd5-a1bf-da6a-2ee6-f2df945f125b AT cs DOT umass DOT edu>
<000501d6c26e$73e1d760$5ba58620$@gmail.com>
<11a20f55-46db-c9b4-1f30-d2181a3aeb9e AT cornell DOT edu>
<eba78a62-b702-ffa3-825b-6345e72d575b AT cs DOT umass DOT edu>
In-Reply-To: <eba78a62-b702-ffa3-825b-6345e72d575b@cs.umass.edu>
Subject: Sv: Sv: Sv: Sv: Sv: Sv: g++ and c++17 filesystem
Date: Wed, 25 Nov 2020 09:02:10 +0100
Message-ID: <000b01d6c301$47673ca0$d635b5e0$@gmail.com>
MIME-Version: 1.0
X-Mailer: Microsoft Outlook 16.0
Thread-Index: AQIMEcHDzo+EBBrhHHj3sFlr53GwtQIBqNbVAy9h9QUA3PghxQI7mYCPAhTJa9sCXpfa/AHDfHWzAafgnf4Bf6X0yAF3M7+8ATG+gL0Ar+aNcajF1kGA
X-Spam-Status: No, score=-3.1 required=5.0 tests=BAYES_00, DKIM_SIGNED,
DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,
SPF_HELO_NONE, 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: <https://cygwin.com/mailman/listinfo/cygwin>,
<mailto:cygwin-request AT cygwin DOT com?subject=subscribe>
From: Kristian Ivarsson via Cygwin <cygwin AT cygwin DOT com>
Reply-To: sten DOT kristian DOT ivarsson AT gmail DOT com
Sender: "Cygwin" <cygwin-bounces AT cygwin DOT com>

> For the specific case C:\Temp, I found this:
> 
> cygpath -ua 'C:\Temp'
> 
>    -> /cygdrive/c/Temp
> 
> cygpath -ua /cygdrive/c/Temp
> 
>    -> /cygdrive/c/Temp
> 
> cygpath -ua '\Temp'
> 
>    -> /cygdrive/c/Temp
> 
> cygpath -ua '/Temp'
> 
>    -> /Temp
> 
> Now Cygwin is open source, so you, too, could grab the code in cygpath and
> call it as a subroutine, maybe, to try to canonicalize a wider range of
> paths.

Yeah, thanx for the tip, but this functionality won't be available on other
*nix-platforms, so some kind of #ifdef is required

> Note the interesting difference between the \Temp and /Temp cases.
> cygpath is processing \Temp as a Windows-like thing, and thus interpreting
> it according the the Windows root for the current drive.  However, it
> processes /Temp and a Posix-like path, which will be in term of the
> _Cygwin_ root, generally the CYgwin install directory.
> 
> Still, if you did this canonicalization first, maybe you would get more
> what you're looking for?  I'm not sure it would be a good idea to insert
> this generally into the Cygwin library stack.  Others more familiar with
> the fine details can probably elaborate why.

I experimented by fiddling around with making the path canonical and as you
say, maybe we will be more successful and that could still be a part of our
code that is not platform dependant

I guess we need to go out of std::filesystem::canonical though because that
is what fails (and unfortunately I guess there's a real bug in the (real)
g++ distro of <filesystem> because the
std::filesystem::path::generic-functions doesn't work as the standard
mandates either)


Once again, thanx for the tips


Best regards,
Kristian


> Regards - Eliot Moss
> --
> 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

--
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