delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2020/04/29/00:52:51

X-Recipient: archive-cygwin AT delorie DOT com
X-Original-To: cygwin AT cygwin DOT com
Delivered-To: cygwin AT cygwin DOT com
DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 63444385DC0A
Authentication-Results: sourceware.org;
dmarc=none (p=none dis=none) header.from=towo.net
Authentication-Results: sourceware.org; spf=none smtp.mailfrom=towo AT towo DOT net
Subject: Re: patch command incorrectly capitalizes filenames that live on
external USB flash drives
To: cygwin AT cygwin DOT com
References: <CAKObCaoqPMb6ebbivTcKpWvF_ADhb1HNFgkkD3mpW6nARD4hWQ AT mail DOT gmail DOT com>
From: Thomas Wolff <towo AT towo DOT net>
X-Tagtoolbar-Keys: D20200429065200044
Message-ID: <2529c289-28fa-1bdf-9aa0-16fce4414cd2@towo.net>
Date: Wed, 29 Apr 2020 06:52:00 +0200
User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:68.0) Gecko/20100101
Thunderbird/68.7.0
MIME-Version: 1.0
In-Reply-To: <CAKObCaoqPMb6ebbivTcKpWvF_ADhb1HNFgkkD3mpW6nARD4hWQ@mail.gmail.com>
X-Provags-ID: V03:K1:csvxWTsN+1jv8cgJRHCbxHYBiPTnMBNlYAnBvC8W7dNGgqCrZnT
d6/BWzf9WUf0whmDodsBpsfggrvmzNiq2hTi+oAdmlBWgoAUcgs0XuW9fP4zPka8PYZREq8
gQfI13/l+rq8WQ7Sh6g19YPs7MJAYol8VJDoA0oBdGmhzDP3uvBv5ntw3XYyO5dUXBwDJQF
ikGyJtA6jdUCevLp07/0w==
X-UI-Out-Filterresults: notjunk:1;V03:K0:K0/g51/njYA=:A/U26kEFzgjbxsuWvzfNXZ
vmCN2lnoWUhLe+CCSeWAckG/Z52tNkHaDbDCAsttlVXG+wk78V+WEQmOQ6RyHVycK/+LH7J3s
j/rsVUoeT68b/MIM8bZ1whpv9XbPVkEK572z3x+AFqJsuH9vE+Wi3bHIvk3ORwLe6WaGb0o04
Yog93Tb4CxjlqtUs30UUlOVS/1q8R219EmJWXvG2XxI3q581SfCVZ0TX0SrCN7lBm6tZ6kjXu
TnKSvTkWe/K8rMI1APeIyxCbM9jfl8nzKeFiUknh/1bPkIX9WFDaQq+dI7P8TCUo7cuhJSloO
vsRVzLRjohLBQLvPP/4vud0aB2kc0qxB2INrrSHF7Fw5BP/P/VmYtpbphJpLx5FECvDP0ZTzP
4dEoTRg3b3n9dTIhkERuJzK+xf660oV2AyKxA2FTitDXlx6Fwy8MVewgCU3Zma+A5Q4HaTwH8
gK2zvMM4aipkCQn33pTHuU/vRPV3VCjF9mAPbe7xm/Y+2ghyPbo5Euy38VvaMK1wbqlnIZTqj
XQszLR76ElOJdKJ7A9fPVuGt6GLaAcermSfcRIQzroP0/EQsL2qculRiqpXqEVRxF3BEQOSzE
Q/QqLmZZzvCN+tvgWX8waKNfD2FpFGtWstO1r4qAArWbXnVFcTyDopPPH7cnC0U/zu78X66bT
TNTQ5xrruJw99SXZxv30fdFEadyFkVyx6ksV7tZSy6sBL8O4s42tBO5GIwb8JQKRva9ygPsmq
N2L0ttVLDSIAGdWYx7qFo1cf3SWa9KxRvwNwM6N4rygbvXmihikaPVLvv2ONwsuDgPF2Qt/Z0
xHKAHiosJxhbT0xNdShmnXe8wu3EeIsdqskkBwZWVE/Jj+/tas=
X-Spam-Status: No, score=-22.2 required=5.0 tests=BAYES_00, GIT_PATCH_0,
GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, KAM_DMARC_STATUS, KAM_EXEURI,
KAM_LAZY_DOMAIN_SECURITY, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_NONE, TXREP,
USB_DRIVES 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-Unsubscribe: <http://cygwin.com/mailman/options/cygwin>,
<mailto:cygwin-request AT cygwin DOT com?subject=unsubscribe>
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>
Errors-To: cygwin-bounces AT cygwin DOT com
Sender: "Cygwin" <cygwin-bounces AT cygwin DOT com>

Am 28.04.2020 um 21:27 schrieb Jason Gross via Cygwin:
> Consider the following script in foo.sh:
> ```
> #!/usr/bin/env bash
>
> set -ex
>
> cd "$1"
> rm -rf foo
> mkdir foo
> cd foo
> cat > Makefile <<EOF
> a
> b
> c
> d
> e
> EOF
> cat > diff <<EOF
> diff --git a/Makefile b/Makefile
> index 9405325..86d2f8c 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -1,5 +1,5 @@
>   a
>   b
> -c
> +ccc
>   d
>   e
> EOF
> patch -p1 -i ./diff
> ls
> ```
>
> If I run `./foo.sh /cygdrive/c/`, I get, as expected,
> ```
> + cd /cygdrive/c/
> + rm -rf foo
> + mkdir foo
> + cd foo
> + cat
> + cat
> + patch -p1 -i ./diff
> patching file Makefile
> + ls
> diff  Makefile
> ```
>
> If I instead run `./foo.sh /cygdrive/h/`, I get
> ```
> + cd /cygdrive/h/
> + rm -rf foo
> + mkdir foo
> + cd foo
> + cat
> + cat
> + patch -p1 -i ./diff
> patching file Makefile
> + ls
> diff  MAKEFILE
> ```
You are throwing a puzzle into the mailing list and if you are lucky, 
someone may like to solve it.
But perhaps: can you try to minimize your test case, please.
Something like: touch Makefile; ls (if that's it).

> My C drive is an internal SSD (NTFS), my H drive is an external flash
> drive (FAT32).  I installed cygwin with the commands:
> ```
> powershell -Command "(New-Object
> Net.WebClient).DownloadFile('http://www.cygwin.com/setup-x86_64.exe',
> 'setup-x86_64.exe')"
> SET CYGMIRROR=http://mirror.easyname.at/cygwin
> SET CYGROOT=H:\cygwin64
> SET CYGCACHE=%CYGROOT%\var\cache\setup
> setup-x86_64.exe -qnNdO -R %CYGROOT% -l %CYGCACHE% -s %CYGMIRROR% -P
> rsync -P patch -P diffutils -P make -P unzip -P m4 -P findutils -P
> time -P wget -P curl -P git -P
> mingw64-x86_64-binutils,mingw64-x86_64-gcc-core,mingw64-x86_64-gcc-g++,mingw64-x86_64-pkg-config,mingw64-x86_64-windows_default_manifest
> -P mingw64-x86_64-headers,mingw64-x86_64-runtime,mingw64-x86_64-pthreads,mingw64-x86_64-zlib
> -P python3
> ```
>
> Running `patch -v` says `GNU patch 2.7.4`.  Note that this happens
> regardless of whether I install cygwin itself on my external flash
> drive or on my internal HD.
>
> This came up when trying to run `opam install findlib` (which fails
> when the home directory is on an external USB drive).
>
> -Jason
>

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