`build-type: configure` configure script isn't passed the GHC exe set with `-w` to be used
- Dominant language
- Haskell
- Stars
- 1.7k
- Forks
- 750
- Avg merge
- 4d 3h
- Merged PRs (30d)
- 28
Description
I found this surprising. I can see this behaviour with
```
$ cabal --version
cabal-install version 3.4.0.0
compiled using version 3.4.0.0 of the Cabal library
```
I confirmed the behaviour with the small cabal package in https://github.com/adamse/cabal-configure-question
Where I can see
```
$ cabal v2-build --verbose -w /home/adam/.ghcup/ghc/8.10.5/bin/ghc-8.10.5
...
/usr/bin/sh //home/adam/src/misc/cabal-q/configure '--with-compiler=ghc' '--prefix=/home/adam/.cabal' '--bindir=/home/adam/.cabal/bin' '--libdir=/home/adam/.cabal/lib/x86_64-linux-ghc-8.10.5/cabal-q-0.1.0.0-inplace' '--libexecdir=/home/adam/.cabal/libexec/x86_64-linux-ghc-8.10.5/cabal-q-0.1.0.0' '--datadir=/home/adam/.cabal/share/x86_64-linux-ghc-8.10.5/cabal-q-0.1.0.0' '--sysconfdir=/home/adam/.cabal/etc' 'CC=/usr/bin/gcc'
...
```
Contributor guide
Research direction
Start by reproducing the verbose `cabal v2-build --verbose -w ...` command from the issue and inspect the generated configure invocation. The configure script currently receives `--with-compiler=ghc` rather than the requested GHC executable; done means the selected compiler path is passed through when using `build-type: configure`.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- haskell
- Domain
- build-system, cli
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 52/100