I have a package that compiles to the executable named ghc.exe
.
When building first time, everything works fine. The install step places the built ghc.exe
in the .stack-work\install\x86_64-windows\lts-2.22\7.8.4\bin
directory. As expected.
However, any subsequent stack build
command will fail:
setup-Simple-Cabal-1.22.4.0-x86_64-windows-ghc-7.8.4.exe: The program 'ghc' version >=6.4 is required but the version of C:\z\.stack-work\install\x86_64-windows\lts-2.22\7.8.4\bin\ghc.exe could not be determined.
setup-Simple-Cabal-1.22.4.0-x86_64-windows-ghc-7.8.4.exe: fd:5: hGetContents: invalid argument (invalid byte sequence)
To built it again I have to delete .stack-work
directory.
It is because stack tried to use .stack-work\install\x86_64-windows\lts-2.22\7.8.4\bin\ghc.exe
— that is not an actual GHC but the locally built package that was just named so.
I expect that stack
should prefer ghc.exe from PATH or its ghc-paths
over the built executables. The results of build should not affect subsequent builds, and overwriting the compiler executable should not be implicit.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4