haskell

haskell package installation problem using GHCup "addDLL: mingw32 or dependencies not loaded. (Win32 error 126)" error message


After installing Sucessfully installing HaskellI open Windows PowerShell and try to run haskellThen I get this Error Message

PS C:\Users\Mee> ghci GHCi, version 9.4.8: https://www.haskell.org/ghc/ :? for help <command line>: addDLL: mingw32 or dependencies not loaded. (Win32 error 126)

What should I do to fix it?

I have upgraded my Windows Power Shell, but the problem still persists.


Solution

  • As the error says, Haskell depends on the GNU Compiler Collection (GCC) [wiki] to compile a program. You install Minimalistic GNU for Windows (MinGW) [wiki] such that the Haskell compiler has access to the GCC.

    You can download MinGW here.