The 'impossible' happened on a fresh installation on Windows 11
Summary
Write a brief description of the issue.
Steps to reproduce
- Buy a Lenovo laptop with Windows 11
- Configure Windows with Spanish keyboard and language, and install all automatic system updates. Restart afterwards.
- Go to haskell.org, click on download, click on GHCup (recommended) and copy the long instruction.
- Paste the long instruction in a powershell terminal. When asked, do not install stack or lhs, and accept all other default recommendations. Restart.
- Install VScode, install GIT, clone a repo with a simple Haskell app that should work
- run
cabal repl
in the same directory as the.cabal
file:
Build profile: -w ghc-9.2.7 -O1
In order, the following will be built (use -v for more details):
- svg-1.0.0.0 (lib) (first run)
Configuring library for svg-1.0.0.0..
Preprocessing library for svg-1.0.0.0..
GHCi, version 9.2.7: https://www.haskell.org/ghc/ :? for help
ghc-9.2.7.exe: Could not load `libstdc++-6.dll'. Reason: addDLL: libstdc++-6.dll or dependencies not loaded. (Win32 error 126)
ghc-9.2.7.exe: panic! (the 'impossible' happened)
(GHC version 9.2.7:
loadArchive "C:\\ghcup\\ghc\\9.2.7\\mingw\\lib\\gcc\\x86_64-w64-mingw32\\10.2.0\\libstdc++.dll.a": failed
Please report this as a GHC bug: https://www.haskell.org/ghc/reportabug
cabal-3.6.2.0.exe: repl failed for svg-1.0.0.0.
Expected behavior
I expected everything to work correctly as it did on my old laptop.
-
cabal build
now creates a file calledMain.exe
which I do not dare to doubleclick. This is not my expected behaviour. -
cabal exec svg-exe
does nothing (instantly jumps to new terminal line with no output, there is aputStrLn
in themain
function which is being ignored) -
cabal repl
prints the error above.
Environment
- GHC version used: 9.2.7
- CABAL version used: 3.6.2.0
Optional:
- Operating System: Windows 11
- System Architecture: Lenovo