I followed the instructions found on this page: https://www.haskell.org/ghcup/
Once you run the online installer all you need to do is restart your terminal.
I ran the command in a PowerShell and installed GHCUP along with the MSYS2 toolchain, then GHC 9.4.8 and cabal.
cabal build
cabal run
Windows 11
Ubuntu 24.04
Raspberry Pi 5