[ANN] GHCup-0.1.18.0 released

How to update/install

Follow the instructions here: GHCup

Or run ghcup upgrade.

Main changes

  1. more interactivity in the TUI interface
  2. fixes for darwin with ld override and ability to pass configure args to bindist
  3. many improvements to ghcup compile hls, hopefully making it a better alternative to bindists

Breaking changes

To improve installation safety, some changes have been made. Some buggy hadrian bindists are now unsupported. GHCup has fixed those bindists here: Index of /ghcup/unofficial-bindists/ghc/curated/

The fix is also upstreamed in newer versions of GHC.

Full changelog

  • Fix tui set wrt #266 by Arjun Kathuria
    • Ask the user to install the tool via prompt when setting an non-installed version
  • improvements to safe (un-)installations
    • bindists that don’t support make DESTDIR=/some/tmp/dir install are now unsupported
    • installed GHC files are now recorded to avoid use of removePathForcibly
    • internally uses a newtype wrapper for user-input paths and restrict destructive operations to validated paths
  • Add --disable-ld-override for darwin bindists wrt #391
  • Allow passing bindist configure args wrt #377
  • use of TMPDIR is dropped… now uses an internal tmp dir ~/.ghcup/tmp
  • improvements to error handling and warnings
  • Require --isolate to have an absolute directory, fixes #367
  • Fix mingw PATH handling wrt #371
  • Add --mingw-path switch to ghcup run
  • Fix ghcup run on windows, fixes #375
  • Improve ghcup compile <hls|ghc>
    • short hashes now work
    • print the long hash in addition to the detected version
  • Improve ghcup compile hls
    • add --git-describe-version switch as an alternative to --overwrite-version
    • Allow to build HLS from hackage (now is the default)
    • Allow to run ‘cabal update’ automatically before the HLS build
    • Fix parser and completer for ‘ghcup compile hls --version’
  • Improve ghcup compile ghc
    • Allow to build from arbitrary GHC source dists
12 Likes

For HLS users it should now be easier to get support for later GHC versions.

E.g. first try to build from hackage with some tricks:

ghcup compile hls --version 1.7.0.0 --ghc 9.2.4 --cabal-update -- --allow-newer --index-state=2022-06-12T00:00:00Z

This augments the currently installed 1.7.0.0 official bindists in ghcup with new GHC versions support.

If that fails (since --allow-newer is quite brutal), you can install from HLS master branch (which may contain new fixes) like so:

ghcup compile hls --git-ref master --git-describe-version --ghc 8.10.7 --ghc 9.2.4 --cabal-update

This however will create a new HLS version in ghcup, e.g. 1.7.0.0-105-gdc682ba1. If you want to switch back to the official bindists, run ghcup set hls 1.7.0.0.

All of this is also documented here: https://www.haskell.org/ghcup/guide/#hls

5 Likes