[Bug 58507] New: Cygwin in Wine cmd "find . -iname '*.exe'" breaks but "find Downloads -iname '*.exe'" works
http://bugs.winehq.org/show_bug.cgi?id=58507 Bug ID: 58507 Summary: Cygwin in Wine cmd "find . -iname '*.exe'" breaks but "find Downloads -iname '*.exe'" works Product: Wine Version: 10.11 Hardware: x86-64 OS: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: -unknown Assignee: wine-bugs(a)winehq.org Reporter: wineryyyyy(a)gmail.com Distribution: --- Running Cygwin's find inside wine cmd using ./ or ../ doesn't work but specifying a directory name does work: z:\home\any\Downloads>find . -iname *.exe find: paths must precede expression: `bogus_test_0.exe' find: possible unquoted pattern after predicate `-iname'? z:\home\any\Downloads>find ../Downloads -iname *.exe find: paths must precede expression: `bogus_test_0.exe' find: possible unquoted pattern after predicate `-iname'? z:\home\any>find Downloads -iname *.exe Downloads/blender-4.4.3-windows-x64/blender-4.4.3-windows-x64/4.4/python/bin/python.exe Downloads/blender-4.4.3-windows-x64/blender-4.4.3-windows-x64/4.4/python/lib/venv/scripts/nt/python.exe Downloads/blender-4.4.3-windows-x64/blender-4.4.3-windows-x64/4.4/python/lib/venv/scripts/nt/pythonw.exe Downloads/blender-4.4.3-windows-x64/blender-4.4.3-windows-x64/blender-launcher.exe Downloads/blender-4.4.3-windows-x64/blender-4.4.3-windows-x64/blender.exe Downloads/bogus_test_0.exe Downloads/bogus_test_1.exe Downloads/Cableguys-ShaperBox-3.5.6-Demo-Win/Cableguys - ShaperBox 3.5.6 Demo/Cableguys - ShaperBox 3.5.6 Demo Setup.exe Downloads/Git-2.50.1-64-bit.exe Downloads/krita-x64-5.2.10/krita-x64-5.2.10/bin/ffmpeg.exe Downloads/krita-x64-5.2.10/krita-x64-5.2.10/bin/ffprobe.exe Downloads/krita-x64-5.2.10/krita-x64-5.2.10/bin/krita.exe Downloads/krita-x64-5.2.10/krita-x64-5.2.10/bin/kritarunner.exe Downloads/Prism Cross v1.05/Prism Cross/challenge/c_test/course/stage/Course Creator.exe Downloads/Prism Cross v1.05/Prism Cross/Prism Cross.exe Steps to reproduce: 1. Download and install cygwin via wine explorer 2. SET CYGWIN_HOME=c:\cygwin64 3. SET PATH=%CYGWIN_HOME%\bin;%PATH% 4. find . -iname *.exe 5. find Downloads -iname *.exe Emacs depends on cygwin's find working to support the most basic vital operations for finding file names and grepping patterns within files in order to be supported on Windows thus Wine. Insights into problems and potential solutions may be found through these previous efforts: https://bugs.winehq.org/buglist.cgi?bug_status=UNCONFIRMED&bug_status=NEW&bu... -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=58507 --- Comment #1 from Stian Low <wineryyyyy(a)gmail.com> --- Previous efforts involving Cygwin were mixed between: 1. Getting Wine to work in Cygwin 2. Getting Cygwin to work in Wine This issue is about 2. Getting Cygwin to work in Wine. https://gitlab.winehq.org/wine/wine/-/wikis/Cygwin-and-More#cygwin-in-wine The primary reason to get Cygwin working in Wine is to get Emacs running in Wine as well as it does in Windows which works about as well as Linux allowing for it to be used almost exclusively between both systems in a very consistent manner. Wine dev efforts may benefit from having Emacs hacking environment available for additional debugging capabilities. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=58507 --- Comment #2 from Alexandre Julliard <julliard(a)winehq.org> --- It sounds like *.exe was expanded by the shell because you have an exe in that directory. You'd need to quote the pattern, as find helpfully suggested. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=58507 Stian Low <wineryyyyy(a)gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |INVALID Status|UNCONFIRMED |RESOLVED --- Comment #3 from Stian Low <wineryyyyy(a)gmail.com> --- (In reply to Alexandre Julliard from comment #2)
It sounds like *.exe was expanded by the shell because you have an exe in that directory. You'd need to quote the pattern, as find helpfully suggested.
Thanks Julliard. You are correct. Somehow I missed that it does indeed work for wine cmd by quoting "*.exe" It doesn't work for emacs eshell however but that is not unusual for eshell since it does an extra layer of expansion. I'll consider the wide side of the issue resolved and fix the remaining issues on emacs side. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=58507 Stian Low <wineryyyyy(a)gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED --- Comment #4 from Stian Low <wineryyyyy(a)gmail.com> --- Closing -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=58507 --- Comment #5 from Stian Low <wineryyyyy(a)gmail.com> --- As final wrap-up with a solution to the emacs side bugs: This form of find works for Emacs eshell: find . \( -iname \*.exe \) -exec ls -ld \{\} \; It is supported by: SET CYGWIN_HOME=c:\cygwin64 SET PATH=%CYGWIN_HOME%\bin;%PATH% c:/cygwin64 [255] $ which find c:/cygwin64/bin/find.exe Cygwin's find supports Emacs M-x find-name-dired which provides path list buffer used to conveniently navigate a file system. For future reference here's some results of eshell find: c:/cygwin64 $ find . \( -iname \*.exe \) -exec ls -ld \{\} \; Cygwin WARNING: Couldn't compute FAST_CWD pointer. This typically occurs if you're using an older Cygwin version on a newer Windows. Please update to the latest available Cygwin version from https://cygwin.com/. If the problem persists, please see https://cygwin.com/problems.html -rwxr-xr-x+ 1 DEB+any DEB+None 53779 Jul 16 2023 ./bin/addftinfo.exe -rwxr-xr-x+ 1 DEB+any DEB+None 36883 Jul 14 2022 ./bin/arch.exe -rwxr-xr-x+ 3 DEB+any DEB+None 108563 Mar 2 2023 ./bin/ash.exe -rwxr-xr-x+ 1 DEB+any DEB+None 55827 Jul 14 2022 ./bin/b2sum.exe -rwxr-xr-x+ 1 DEB+any DEB+None 42003 Jul 14 2022 ./bin/base32.exe -rwxr-xr-x+ 1 DEB+any DEB+None 41491 Jul 14 2022 ./bin/base64.exe -rwxr-xr-x+ 1 DEB+any DEB+None 36371 Jul 14 2022 ./bin/basename.exe -rwxr-xr-x+ 1 DEB+any DEB+None 50195 Jul 14 2022 ./bin/basenc.exe -rwxr-xr-x+ 2 DEB+any DEB+None 854035 Jan 23 2024 ./bin/bash.exe Luckily the FAST_CWD doesn't break Emacs M-x find-name-dired either. Here's the buffer produced by Emacs M-x find-name-dired which supports actions per item consistent with Linux and Windows. c:/cygwin64/: find . \( -iname \*.exe \) -exec ls -ld \{\} \; Cygwin WARNING: Couldn't compute FAST_CWD pointer. This typically occurs if you're using an older Cygwin version on a newer Windows. Please update to the latest available Cygwin version from https://cygwin.com/. If the problem persists, please see https://cygwin.com/problems.html -rwxr-xr-x+ 1 DEB+any DEB+None 53779 Jul 16 2023 bin/addftinfo.exe -rwxr-xr-x+ 1 DEB+any DEB+None 36883 Jul 14 2022 bin/arch.exe -rwxr-xr-x+ 3 DEB+any DEB+None 108563 Mar 2 2023 bin/ash.exe -rwxr-xr-x+ 1 DEB+any DEB+None 55827 Jul 14 2022 bin/b2sum.exe -rwxr-xr-x+ 1 DEB+any DEB+None 42003 Jul 14 2022 bin/base32.exe -rwxr-xr-x+ 1 DEB+any DEB+None 41491 Jul 14 2022 bin/base64.exe So far FAST_CWD seems largely be ignorable as a red herring of Cygwin integration problems. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=58507 --- Comment #6 from Stian Low <wineryyyyy(a)gmail.com> --- This key piece was missing from the last message which is required for Emacs M-x find-name-dired to work: (setq shell-file-name "c:/cygwin64/bin/bash.exe") Write it to ~/.emacs so that future Emacs sessions are automatically mapped to Cygwin environment. Here's a a more complete list of relevant parts in my ~/.emacs that support mapping Cygwin and MinGW environments: (setq shell-file-name "c:/cygwin64/bin/bash.exe") (setenv "CYGWIN_HOME" "c:/cygwin64/") (setenv "PATH" (concat "c:/cygwin64/bin;" (getenv "PATH"))) (setq exec-path (append '("c:/cygwin64/bin") exec-path )) (setenv "PATH" (concat "c:/x86_64-15.1.0-release-win32-seh-msvcrt-rt_v12-rev0/mingw64/bin;" (getenv "PATH"))) (setq exec-path (append '("c:/x86_64-15.1.0-release-win32-seh-msvcrt-rt_v12-rev0/mingw64/bin") exec-path )) -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
participants (1)
-
WineHQ Bugzilla