https://bugs.winehq.org/show_bug.cgi?id=53155
Bug ID: 53155 Summary: msys2 cannot be installed under wine Product: Wine Version: 7.10 Hardware: x86-64 OS: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: -unknown Assignee: wine-bugs@winehq.org Reporter: hramrach@gmail.com Distribution: ---
Created attachment 72589 --> https://bugs.winehq.org/attachment.cgi?id=72589 terminal output
There is a number of bugs that reference msys2 but all are marked as staging sp presumably they should be addressed in the staging version.
nonetheless msys2 installer gets still stuck at 66%
sha256sum Downloads/msys2-x86_64-20220603.exe 6e5a76e36a651542e6b907a39776effb7670a139d6a017c3808fdcfaca84ee83 Downloads/msys2-x86_64-20220603.exe
https://bugs.winehq.org/show_bug.cgi?id=53155
msuchanek@suse.de changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |msuchanek@suse.de
https://bugs.winehq.org/show_bug.cgi?id=53155
Michal Suchanek hramrach@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |hramrach@gmail.com
--- Comment #1 from Michal Suchanek hramrach@gmail.com --- Distribution: openSUSE Tumbleweed
https://bugs.winehq.org/show_bug.cgi?id=53155
Austin English austinenglish@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |austinenglish@gmail.com
--- Comment #2 from Austin English austinenglish@gmail.com --- Your output shows that you're using staging?
https://bugs.winehq.org/show_bug.cgi?id=53155
--- Comment #3 from Michal Suchanek hramrach@gmail.com --- Yes, using staging or plain build does not make any visible difference although all bugs related to msys I found are marked as staging
https://bugs.winehq.org/show_bug.cgi?id=53155
Bernhard Übelacker bernhardu@mailbox.org changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |bernhardu@mailbox.org
--- Comment #4 from Bernhard Übelacker bernhardu@mailbox.org --- I could reproduce the hang at 66%. At that state I see a process "C:\msys64\usr\bin\bash.exe --login -c exit" that never finishes. Attaching to it shows some stack below NtCreateNamedPipeFile. And applying those two patches by Jinoh Kang from bug #52105 make it continue some further.
Then I hit a crash in libfreetype.so.6, so I applied those hacks from December attached to bug #47808.
And finally the message about "Implement reading multiple entries" appeared, which can be worked around by appyling the not yet commited parts of the patch attached to bug #52585.
With those modifications the Installer went through and I could start a bash instance myself. Checking the "Start now MSYS2 64bit" seem not to open a new window, instead the msys2_shell.cmd seems to be stuck in an endlessloop caused by the line "...MINGW32))& goto :checkparams", where cmd seems to have issues with a closing bracket, therefore the "shift" command is never called.
And finally I found bug #43193, which overall sound quite similar to this bug. (This is reported against wine-staging, but has not Status "STAGED".)
https://bugs.winehq.org/show_bug.cgi?id=53155
--- Comment #5 from Michal Suchanek hramrach@gmail.com --- Thanks for the summary.
None of these bugs names msys2 so it's difficult to make the connection - except the last one which was staging-only back then, has nothing actionable, and now the installer fails even without staging patches.
With the patches applied I cannot run wine at all, even wineboot -u hangs. That's as far is git gets for now.
https://bugs.winehq.org/show_bug.cgi?id=53155
--- Comment #6 from Bernhard Übelacker bernhardu@mailbox.org --- Created attachment 72610 --> https://bugs.winehq.org/attachment.cgi?id=72610 combined patch from the other bugs
(In reply to Michal Suchanek from comment #5)
None of these bugs names msys2 so it's difficult to make the connection
It seems Msys2 is using parts of Cygwin, which is mentioned there. I had played a little with Cygwin in the past, therefore I was aware of these other bugs.
With the patches applied I cannot run wine at all, even wineboot -u hangs.
I attached what I had applied to vanilla wine git f86a66b6 from a few days ago. With that msys2 setup works here, still taking some time at 66%. Later "wine c:\msys64\usr\bin\bash.exe --login" shows at least the interactive prompt.
https://bugs.winehq.org/show_bug.cgi?id=53155
--- Comment #7 from Michal Suchanek hramrach@gmail.com --- Thanks for the patch.
The problem is combining the fix for bug #52105 with the staging patches, without staging patches there is no problem - I can finish the installation and start the shell.
I see that in your patch the conflict resolution is different from the trivial one I used. Maybe it would be helpful attaching the updated patches to the respective bugs.
https://bugs.winehq.org/show_bug.cgi?id=53155
--- Comment #8 from Michal Suchanek hramrach@gmail.com --- I needed this additional patch to install anything with pacman
https://source.winehq.org/patches/data/239430
However, all cygwin applications are very unreliable and tend to lock up.
https://bugs.winehq.org/show_bug.cgi?id=53155
Joerg Schiermeier mywine@schiermeier-it.de changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |mywine@schiermeier-it.de
--- Comment #9 from Joerg Schiermeier mywine@schiermeier-it.de --- I'm sorry to tell you: this bug still exists in wine v7.11 published on Friday, 17th June 2022.
https://bugs.winehq.org/show_bug.cgi?id=53155
Joel Holdsworth joel@airwebreathe.org.uk changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |joel@airwebreathe.org.uk
https://bugs.winehq.org/show_bug.cgi?id=53155
--- Comment #10 from Bernhard Übelacker bernhardu@mailbox.org --- Bug# 54938 seems about the same hang in the installer.
https://bugs.winehq.org/show_bug.cgi?id=53155
Bernhard Übelacker bernhardu@mailbox.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Keywords| |download, source
http://bugs.winehq.org/show_bug.cgi?id=53155
Serge S. Gulin gulin.serge@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |gulin.serge@gmail.com
--- Comment #11 from Serge S. Gulin gulin.serge@gmail.com --- MSYS fresh update hangs. Probably due of the following:
Moreover, because the fact that NtSetInformationFile() in set_pipe_non_blocking(true) fails with STATUS_PIPE_BUSY if the pipe is not empty has been found, query handle is not necessary anymore. This allows the implementation much simpler than before.
https://github.com/cygwin/cygwin/commit/7ed9adb356df61114bb3fa3d0efc098c0501...
See details: https://github.com/msys2/MSYS2-packages/issues/682#issuecomment-2845257764
http://bugs.winehq.org/show_bug.cgi?id=53155
--- Comment #12 from Bernhard Übelacker bernhardu@mailbox.org --- (In reply to Serge S. Gulin from comment #11)
MSYS fresh update hangs. Probably due of the following:
Moreover, because the fact that NtSetInformationFile() in set_pipe_non_blocking(true) fails with STATUS_PIPE_BUSY if the pipe is not empty has been found, query handle is not necessary anymore. This allows the implementation much simpler than before.
https://github.com/cygwin/cygwin/commit/ 7ed9adb356df61114bb3fa3d0efc098c0501921c
See details: https://github.com/msys2/MSYS2-packages/issues/682#issuecomment-2845257764
Hello Serge, unfortunately there are too many such "msys2 installation hangs" around.
Please have a look at bug #55138, bug #53574 and bug #57424. With their three patches applied I was able to finish installation of msys2-x86_64-20250221.exe and interact with the opened msys2 shell. (On top of vanilla wine, not the staging patch-set.)
http://bugs.winehq.org/show_bug.cgi?id=53155
Bernhard Übelacker bernhardu@mailbox.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Attachment #72610|0 |1 is obsolete| |
http://bugs.winehq.org/show_bug.cgi?id=53155
--- Comment #13 from Serge S. Gulin gulin.serge@gmail.com --- Yep, it is known, but the issue above is a little different.
I was able to setup MSYS2 and get the shell but the issue is about another step.
It hangs on `pacman -Syyuu` from https://gitforwindows.org/install-inside-msys2-proper.
So, the whole full system upgrade stopped to work.
http://bugs.winehq.org/show_bug.cgi?id=53155
--- Comment #14 from Bernhard Übelacker bernhardu@mailbox.org --- (In reply to Serge S. Gulin from comment #13)
It hangs on `pacman -Syyuu` from
That was the needed info. I adjusted the patch in bug #57424, please check if that solves your issue?
http://bugs.winehq.org/show_bug.cgi?id=53155
--- Comment #15 from Serge S. Gulin gulin.serge@gmail.com ---
I adjusted the patch in bug #57424, please check if that solves your issue?
It works, proof:
https://gitlab.haskell.org/gulin.serge/ci-wine-msys2-arm64ec/-/jobs/2186223/...
http://bugs.winehq.org/show_bug.cgi?id=53155
--- Comment #16 from Serge S. Gulin gulin.serge@gmail.com --- Well, still some care is needed. But I have no a minimal sample.
Yep, the patch allowed me to upgrade MSYS2. MSYS2's self upgrade does not hang now. But that upgraded version now hangs at some point in `./configure ...` of GHC CI process like here: https://gitlab.haskell.org/ghc/ghc/-/jobs/2187439. And I am unable to create a minimal reproduction sample.
Fortunately origin MSYS2 (I mean `msys2-x86_64-20250221.exe`) does not hangs there. So, better do not upgrade it if you run it under Wine.
http://bugs.winehq.org/show_bug.cgi?id=53155
--- Comment #17 from Joel Holdsworth joel@airwebreathe.org.uk --- Is this driven by AutoTools? If so, can you dig through config.log to find out the command that failed? Then see if you can reproduce the failure if you run the command directly?
http://bugs.winehq.org/show_bug.cgi?id=53155
--- Comment #18 from Serge S. Gulin gulin.serge@gmail.com --- It seemed to me that the following caused the hang:
``` sed ' /^ac_cv_env_/b end t clear :clear s/^([^=]*)=(.*[{}].*)$/test ${\1+y} || &/ t end s/^([^=]*)=(.*)$/\1=${\1=\2}/ :end' >>confcache ```
It is from `autom4te`.
When I kill this sed and еру parent shell, it continues the build. Strange. May be it can help with some clues what is going on. Again, origin MSYS2 (without full upgrade) works fine here.
http://bugs.winehq.org/show_bug.cgi?id=53155
--- Comment #19 from Joel Holdsworth joel@airwebreathe.org.uk --- That's presumably not the full command pipeline? What is the input to sed? Can you get the same command to hang when invoked directly from the shell? Can you simplify the command; whittle it down to the very minimum while still reproducing the bug?
http://bugs.winehq.org/show_bug.cgi?id=53155
--- Comment #20 from Serge S. Gulin gulin.serge@gmail.com --- Well, it is a very fragile. Serial run shows different results. Stochastic reproduction. The sample above is most frequent but it does not reproduce in my attempts to execute some piece of bash.
http://bugs.winehq.org/show_bug.cgi?id=53155
--- Comment #21 from Serge S. Gulin gulin.serge@gmail.com --- Direct call `$SHELL ./configure ...` does not give a hang. I mean if I push it like this:
``` /opt/wine-arm64ec-msys2-deb12/bin/wine c:/msys64/usr/bin/bash.exe -l -c 'cd _build/bindist/ghc-9.13.20250509-aarch64-unknown-mingw32; sh configure --prefix="Z:\home\ghc\ghc/_build/reloc-bindist/ghc-9.13.20250509-aarch64-unknown-mingw32" MergeObjsCmd=' ```
I tried 20 times to run it through the day and catch the hang.
But the calling it from GHC's Hadrian (https://gitlab.haskell.org/ghc/ghc/-/blob/master/hadrian/README.md, a build tool) as a sub target of compilation gives the hang immediately. I still see no crucial difference, I am in walking around mode. It just uses OS's "create process" for this.