4
votes

I put stack.exe v0.1.2.2 in one of my PATH dirs, then install ghc-7.8.4 via stack setup.

I trying to install ghc-mod and obtain strange error Setup.hs: does not exist:

stack install ghc-mod
Using resolver: lts-2.21 from global config file: C:\Users\martynov_p\AppData\Roaming\stack\global\stack.yaml
ghc-paths-0.1.0.9: configure
data-default-class-0.0.1: configure
dlist-0.7.1.1: configure
ansi-terminal-0.6.2.1: configure
hscolour-1.22: configure
extra-1.1: configure
mtl-2.1.3.1: configure
cmdargs-0.10.13: configure
Progress: 8/54
--  While building package cmdargs-0.10.13 using:
      C:\\Users\\martynov_p\\appdata\\Local\\Programs\\stack\\x86_64-windows\\ghc-7.8.4\\bin\\runhaskell.exe -package=Cabal-1.18.1.5 -clear-package-db -global-package-db -package-db=C:\Users\martynov_p\AppData\Roaming\stack\snapshots\x86_64-windows\lts-2.21\7.8.4\pkgdb\ C:\Users\MARTYN~1\AppData\Local\Temp\stack12088\Setup.hs --builddir=.stack-work\dist\x86_64-windows\Cabal-1.18.1.5\ configure --user --package-db=clear --package-db=global --package-db=C:\Users\martynov_p\AppData\Roaming\stack\snapshots\x86_64-windows\lts-2.21\7.8.4\pkgdb\ --constraint=base==4.7.0.2 --constraint=filepath==1.3.0.2 --constraint=process==1.2.0.0 --constraint=template-haskell==2.9.0.0 --constraint=transformers==0.3.0.0 --libdir=C:\Users\martynov_p\AppData\Roaming\stack\snapshots\x86_64-windows\lts-2.21\7.8.4\lib --bindir=C:\Users\martynov_p\AppData\Roaming\stack\snapshots\x86_64-windows\lts-2.21\7.8.4\bin --datadir=C:\Users\martynov_p\AppData\Roaming\stack\snapshots\x86_64-windows\lts-2.21\7.8.4\share --docdir=C:\Users\martynov_p\AppData\Roaming\stack\snapshots\x86_64-windows\lts-2.21\7.8.4\doc\cmdargs-0.10.13 --htmldir=C:\Users\martynov_p\AppData\Roaming\stack\snapshots\x86_64-windows\lts-2.21\7.8.4\doc\cmdargs-0.10.13 --haddockdir=C:\Users\martynov_p\AppData\Roaming\stack\snapshots\x86_64-windows\lts-2.21\7.8.4\doc\cmdargs-0.10.13
    Process exited with code: ExitFailure 1
    Logs have been written to: "C:\\Users\\martynov_p\\AppData\\Roaming\\stack\\global\\.stack-work\\logs\\cmdargs-0.10.13.log"

    Configuring cmdargs-0.10.13...
    Setup.hs: does not exist
1
Maybe you can include what's in C:\\Users\\martynov_p\\AppData\\Roaming\\stack\\global\\.stack-work\\logs\\cmdargs-0.10.13.log also? - adamse
@adamse nothing new here:Configuring cmdargs-0.10.13... Setup.hs: does not exist - Pavel Martynov
I've run into a similar problem: for me, it only happens on Windows, and only with GHC 7.10.{1,2}. I can build my project on CentOS, Ubuntu, and OS X with GHC 7.10.{1,2}, and on Windows with GHC 7.8.4. On Windows, this error doesn't seem to have anything to do with a specific dependency: e.g., which package fails in this way depends on how many jobs I run concurrently (the -j option to Stack). - ntc2
I had the same problem with MinGHC 7.8.4 x64 (for Windows). The less then ideal solution? Install MinGHC 7.8.4 i386. Things started to work, then. As an additional info, I inspected the -j argument @ntc2 has told about, but the problem persisted for any number of concurrent jobs. - Guiraldelli

1 Answers

1
votes

This is probably due to a bug in cabal, and is resolved by upgrading your cabal version or switching to a newer stackage resolver. See

https://github.com/haskell/cabal/issues/1733

https://github.com/commercialhaskell/stack/issues/943