Closed mpilgrem closed 5 years ago
I can build on a different Windows 10 machine, so it must be the machine not stack
- so closing.
One difference between the two Windows 10 machines is that the one that works does not have a space on the path and the the one that does not work does have a space on the path.
I located the config.log
file referred to in the error message and part of it reads as below, suggesting that the test that is failing does not handle paths with a space in them:
configure:2674: checking whether the C compiler works
configure:2696: C:\Users\Mike Pilgrem\AppData\Local\Programs\stack\X86_64~1\ghc-8.2.2\mingw\bin\gcc.exe -fno-stack-protector conftest.c >&5
./configure: line 2698: C:\Users\Mike: No such file or directory
configure:2700: $? = 127
configure:2738: result: no
The solution is, therefore, to set local-programs-path
in the non-project-specific config (C:\sr\config.yaml
) to be a path without a space in it.
As far as I can see, the current documentation does not warn Windows users that may be necessary.
Just to confirm, based on your title change: are you saying that you've also tested this with a new build of the Stack from master and experience the same problem? Can you confirm what the stack build --verbose
output looks like?
I've just tested on my Windows 10 machine with a space in my local-programs-path
, and both installing GHC and building packages (including process
) works. In fact, I just noticed that my default programs path includes a space in it as well. I'm unable to reproduce this problem. Without a repro, my recommendation is we add a line to the docs recommending setting STACK_ROOT to a path without spaces if this problem is encountered and close.
Without a space in the local-programs-path
I could stack install
version Version 1.10.0, Git revision b6102fdf8a6017e7fee131cf24f470bf1a396665 (7418 commits) x86_64 hpack-0.31.1
.
With a space in that path, on the same machine, and using that version of stack, I cannot stack build
. It repeatedly fails with network
and process
(in the same way as above), ultimately boiling down to:
C:\Users\Mike Pilgrem\Documents\Code\GitHub\stack>stack build
WARNING: Ignoring lens's bounds on Cabal (>=1.10 && <2.3); using Cabal-2.4.0.1.
Reason: trusting snapshot over cabal file dependency information.
network > configure
network > [1 of 2] Compiling Main ( C:\Users\Mike Pilgrem\AppData\Local\Temp\stack158612\network-2.6.3.6\Setup.hs, C:\Users\Mike Pilgrem\AppData\Local\Temp\stack158612\network-2.6.3.6\.stack-work\dist\5c8418a7\setup\Main.o )
network > [2 of 2] Compiling StackSetupShim ( C:\sr\setup-exe-src\setup-shim-Z6RU0evB.hs, C:\Users\Mike Pilgrem\AppData\Local\Temp\stack158612\network-2.6.3.6\.stack-work\dist\5c8418a7\setup\StackSetupShim.o )
network > Linking C:\Users\Mike Pilgrem\AppData\Local\Temp\stack158612\network-2.6.3.6\.stack-work\dist\5c8418a7\setup\setup.exe ...
network > Configuring network-2.6.3.6...
network > configure: WARNING: unrecognized options: --with-compiler
network > configure: loading site script /usr/local/etc/config.site
network > checking build system type... x86_64-w64-mingw32
network > checking host system type... x86_64-w64-mingw32
network > checking for gcc... C:\Users\Mike Pilgrem\AppData\Local\Programs\stack\X86_64~1\ghc-8.2.2\mingw\bin\gcc.exe
network > checking whether the C compiler works... no
network > configure: error: in `/c/Users/Mike Pilgrem/AppData/Local/Temp/stack158612/network-2.6.3.6':
network > configure: error: C compiler cannot create executables
network > See `config.log' for more details
process > configure
process > [1 of 2] Compiling Main ( C:\Users\Mike Pilgrem\AppData\Local\Temp\stack158612\process-1.6.3.0\Setup.hs, C:\Users\Mike Pilgrem\AppData\Local\Temp\stack158612\process-1.6.3.0\.stack-work\dist\5c8418a7\setup\Main.o )
process > [2 of 2] Compiling StackSetupShim ( C:\sr\setup-exe-src\setup-shim-Z6RU0evB.hs, C:\Users\Mike Pilgrem\AppData\Local\Temp\stack158612\process-1.6.3.0\.stack-work\dist\5c8418a7\setup\StackSetupShim.o )
process > Linking C:\Users\Mike Pilgrem\AppData\Local\Temp\stack158612\process-1.6.3.0\.stack-work\dist\5c8418a7\setup\setup.exe ...
process > Configuring process-1.6.3.0...
process > configure: WARNING: unrecognized options: --with-compiler
process > configure: loading site script /usr/local/etc/config.site
process > checking for gcc... C:\Users\Mike Pilgrem\AppData\Local\Programs\stack\X86_64~1\ghc-8.2.2\mingw\bin\gcc.exe
process > checking whether the C compiler works... no
process > configure: error: in `/c/Users/Mike Pilgrem/AppData/Local/Temp/stack158612/process-1.6.3.0':
process > configure: error: C compiler cannot create executables
process > See `config.log' for more details
-- While building package process-1.6.3.0 using:
C:\Users\Mike Pilgrem\AppData\Local\Temp\stack158612\process-1.6.3.0\.stack-work\dist\5c8418a7\setup\setup --builddir=.stack-work\dist\5c8418a7 configure --user --package-db=clear --package-db=global --package-db=C:\sr\snapshots\1addba98\pkgdb --libdir=C:\sr\snapshots\1addba98\lib --bindir=C:\sr\snapshots\1addba98\bin --datadir=C:\sr\snapshots\1addba98\share --libexecdir=C:\sr\snapshots\1addba98\libexec --sysconfdir=C:\sr\snapshots\1addba98\etc --docdir=C:\sr\snapshots\1addba98\doc\process-1.6.3.0 --htmldir=C:\sr\snapshots\1addba98\doc\process-1.6.3.0 --haddockdir=C:\sr\snapshots\1addba98\doc\process-1.6.3.0 --dependency=Win32=Win32-2.5.4.1 --dependency=base=base-4.10.1.0 --dependency=deepseq=deepseq-1.4.3.0 --dependency=directory=directory-1.3.0.2 --dependency=filepath=filepath-1.4.1.2 "--extra-include-dirs=C:\\Users\\Mike Pilgrem\\AppData\\Local\\Programs\\stack\\x86_64-windows\\msys2-20180531\\mingw64\\include" "--extra-lib-dirs=C:\\Users\\Mike Pilgrem\\AppData\\Local\\Programs\\stack\\x86_64-windows\\msys2-20180531\\mingw64\\lib" "--extra-lib-dirs=C:\\Users\\Mike Pilgrem\\AppData\\Local\\Programs\\stack\\x86_64-windows\\msys2-20180531\\mingw64\\bin" --exact-configuration --ghc-option=-fhide-source-paths
Process exited with code: ExitFailure 77
-- While building package network-2.6.3.6 using:
C:\Users\Mike Pilgrem\AppData\Local\Temp\stack158612\network-2.6.3.6\.stack-work\dist\5c8418a7\setup\setup --builddir=.stack-work\dist\5c8418a7 configure --user --package-db=clear --package-db=global --package-db=C:\sr\snapshots\1addba98\pkgdb --libdir=C:\sr\snapshots\1addba98\lib --bindir=C:\sr\snapshots\1addba98\bin --datadir=C:\sr\snapshots\1addba98\share --libexecdir=C:\sr\snapshots\1addba98\libexec --sysconfdir=C:\sr\snapshots\1addba98\etc --docdir=C:\sr\snapshots\1addba98\doc\network-2.6.3.6 --htmldir=C:\sr\snapshots\1addba98\doc\network-2.6.3.6 --haddockdir=C:\sr\snapshots\1addba98\doc\network-2.6.3.6 --dependency=base=base-4.10.1.0 --dependency=bytestring=bytestring-0.10.8.2 "--extra-include-dirs=C:\\Users\\Mike Pilgrem\\AppData\\Local\\Programs\\stack\\x86_64-windows\\msys2-20180531\\mingw64\\include" "--extra-lib-dirs=C:\\Users\\Mike Pilgrem\\AppData\\Local\\Programs\\stack\\x86_64-windows\\msys2-20180531\\mingw64\\lib" "--extra-lib-dirs=C:\\Users\\Mike Pilgrem\\AppData\\Local\\Programs\\stack\\x86_64-windows\\msys2-20180531\\mingw64\\bin" --exact-configuration --ghc-option=-fhide-source-paths
Process exited with code: ExitFailure 77
Progress 2/57
and the verbose version is:
C:\Users\Mike Pilgrem\Documents\Code\GitHub\stack>stack build --verbose
Version 1.10.0, Git revision b6102fdf8a6017e7fee131cf24f470bf1a396665 (7418 commits) x86_64 hpack-0.31.1
2019-04-17 22:33:14.873219: [debug] Checking for project config at: C:\Users\Mike Pilgrem\Documents\Code\GitHub\stack\stack.yaml
2019-04-17 22:33:14.873219: [debug] Loading project config file stack.yaml
2019-04-17 22:33:15.024327: [debug] Completing package location information from ansi-terminal-0.8.1@sha256:4cebbd2034dcd9029369c0a49c72666be8dacd11a2827d33bcfa539f2933614a,3116
2019-04-17 22:33:15.024327: [debug] Completing package location information from Cabal-2.4.0.1@rev:0
2019-04-17 22:33:15.067285: [debug] Added in cabal file hash: Cabal-2.4.0.1@sha256:81b388aab88f21eea46425f25d7b0256edda6473cb40eed949a94f83b31a69a7,21190
2019-04-17 22:33:15.067285: [debug] Completing package location information from infer-license-0.2.0@rev:0
2019-04-17 22:33:15.108275: [debug] Added in cabal file hash: infer-license-0.2.0@sha256:98dbe0e8d726fd698f9961e69cc69343f37952b4b7428283d0b8dbe3b09f8125,1804
2019-04-17 22:33:15.108275: [debug] Completing package location information from hpack-0.31.1@rev:0
2019-04-17 22:33:15.148251: [debug] Added in cabal file hash: hpack-0.31.1@sha256:636d511ed9bbacf0f27610f70564f123cecbd576405e7dde0757e027e49f94f2,4406
2019-04-17 22:33:15.149238: [debug] Completing package location information from githash-0.1.3.0@rev:0
2019-04-17 22:33:15.189227: [debug] Added in cabal file hash: githash-0.1.3.0@sha256:746669e12afb1af23eb64fc84e79ef356ecf26b0ad1d4374744a513078f4d0e8,1549
2019-04-17 22:33:15.190231: [debug] Completing package location information from rio-orphans-0.1.1.0@sha256:15600084c56ef4e1f22ac2091d10fa6ed62f01f531d819c6a5a19492212a76c9
2019-04-17 22:33:15.192214: [debug] Added in cabal file hash: rio-orphans-0.1.1.0@sha256:15600084c56ef4e1f22ac2091d10fa6ed62f01f531d819c6a5a19492212a76c9,1612
2019-04-17 22:33:15.192214: [debug] Completing package location information from yaml-0.10.4.0@rev:0
2019-04-17 22:33:15.227205: [debug] Added in cabal file hash: yaml-0.10.4.0@sha256:faaef7251bf05095ab34a3e716cfb4aaa3775aa23e38471ab8e8f44e59040b8f,5775
2019-04-17 22:33:15.228192: [debug] Completing package location information from tar-conduit-0.3.0@sha256:c220b7a74b986445d08706aed77f17f82807d0133a5f3a760f53d587d20865b2,2928
2019-04-17 22:33:15.230193: [debug] Completing package location information from hackage-security-0.5.3.0@rev:2
2019-04-17 22:33:15.451500: [debug] Added in cabal file hash: hackage-security-0.5.3.0@sha256:8349c7cfa69bbfb4c0ac3bf4da5dad05ec4dbead90427a26fb907e0e112a9b43,11351
2019-04-17 22:33:15.451500: [debug] Completing package location information from http-api-data-0.3.8.1@rev:1
2019-04-17 22:33:15.520518: [debug] Added in cabal file hash: http-api-data-0.3.8.1@sha256:fdf8a3397221b819697dfb50b5eab9175f96a3cfcce74012a1b36551af5a83a0,3443
2019-04-17 22:33:15.520518: [debug] Completing package location information from cabal-doctest-1.0.6@rev:2
2019-04-17 22:33:15.790179: [debug] Added in cabal file hash: cabal-doctest-1.0.6@sha256:c0b4a5b1ff38d2867e7003b4be59f3bd7e8e204ab8c988d96d3a77472ae671cd,1408
2019-04-17 22:33:15.805806: [debug] Completing package location information from unliftio-0.2.8.0@sha256:5a47f12ffcee837215c67b05abf35dffb792096564a6f81652d75a54668224cd,2250
2019-04-17 22:33:15.805806: [debug] Completing package location information from happy-1.19.9@sha256:f8c774230735a390c287b2980cfcd2703d24d8dde85a01ea721b7b4b4c82944f,4667
2019-04-17 22:33:15.805806: [debug] Completing package location information from fsnotify-0.3.0.1@rev:1
2019-04-17 22:33:15.990733: [debug] Added in cabal file hash: fsnotify-0.3.0.1@sha256:58bb530d7acf93eb4ed69473e32a1485581815f04f69dfc8a278523781ba49dd,2988
2019-04-17 22:33:15.990733: [debug] Completing package location information from process-1.6.3.0@sha256:fc77cfe75a9653b8c54ae455ead8c06cb8adc4d7a340984d84d8ca880b579919,2370
2019-04-17 22:33:15.990733: [debug] Completing package location information from persistent-2.9.2@rev:0
2019-04-17 22:33:16.021990: [debug] Added in cabal file hash: persistent-2.9.2@sha256:13d2e239751b75be0c20b91daaa5677a6fe1b33916e8bb21bd972949d17c0563,4781
2019-04-17 22:33:16.021990: [debug] Completing package location information from persistent-sqlite-2.9.3@rev:0
2019-04-17 22:33:16.075399: [debug] Added in cabal file hash: persistent-sqlite-2.9.3@sha256:2dcea3acf7fc2de613d320903f68a084e0a3c68940e2f0900724e3413f72c677,3873
2019-04-17 22:33:16.075399: [debug] Running hpack on C:\Users\Mike Pilgrem\Documents\Code\GitHub\stack\package.yaml
2019-04-17 22:33:16.206941: [debug] hpack output unchanged in C:\Users\Mike Pilgrem\Documents\Code\GitHub\stack\stack.cabal
2019-04-17 22:33:16.206941: [debug] Running hpack on C:\Users\Mike Pilgrem\Documents\Code\GitHub\stack\subs\pantry\package.yaml
2019-04-17 22:33:16.238187: [debug] hpack output unchanged in C:\Users\Mike Pilgrem\Documents\Code\GitHub\stack\subs\pantry\pantry.cabal
2019-04-17 22:33:16.238187: [debug] Running hpack on C:\Users\Mike Pilgrem\Documents\Code\GitHub\stack\subs\curator\package.yaml
2019-04-17 22:33:16.253812: [debug] hpack output unchanged in C:\Users\Mike Pilgrem\Documents\Code\GitHub\stack\subs\curator\curator.cabal
2019-04-17 22:33:16.253812: [debug] Running hpack on C:\Users\Mike Pilgrem\Documents\Code\GitHub\stack\subs\http-download\package.yaml
2019-04-17 22:33:16.253812: [debug] hpack output unchanged in C:\Users\Mike Pilgrem\Documents\Code\GitHub\stack\subs\http-download\http-download.cabal
2019-04-17 22:33:16.253812: [debug] Running hpack on C:\Users\Mike Pilgrem\Documents\Code\GitHub\stack\subs\rio-prettyprint\package.yaml
2019-04-17 22:33:16.269435: [debug] hpack output unchanged in C:\Users\Mike Pilgrem\Documents\Code\GitHub\stack\subs\rio-prettyprint\rio-prettyprint.cabal
2019-04-17 22:33:16.275982: [debug] Asking for a supported GHC version
2019-04-17 22:33:16.275982: [debug] Installed tools:
- msys2-20180531
- ghc-8.6.4
- ghc-8.2.2
2019-04-17 22:33:16.275982: [debug] Potential GHC builds: standard
2019-04-17 22:33:16.275982: [debug] Found already installed GHC builds: standard
2019-04-17 22:33:16.275982: [debug] SELECT "id","actual_version","arch","ghc_path","ghc_size","ghc_modified","ghc_pkg_path","runghc_path","haddock_path","cabal_version","global_db","global_db_cache_size","global_db_cache_modified","info","global_dump" FROM "compiler_cache" WHERE "ghc_path"=?; [PersistText "C:\\Users\\Mike Pilgrem\\AppData\\Local\\Programs\\stack\\x86_64-windows\\ghc-8.2.2\\bin\\ghc-8.2.2.EXE"]
2019-04-17 22:33:16.338498: [debug] Loaded compiler information from cache
2019-04-17 22:33:16.338498: [debug] Asking for a supported GHC version
2019-04-17 22:33:16.338498: [debug] Resolving package entries
2019-04-17 22:33:16.338498: [debug] Parsing the targets
2019-04-17 22:33:16.338498: [debug] Checking flags
2019-04-17 22:33:16.338498: [debug] SourceMap constructed
2019-04-17 22:33:16.354120: [debug] Starting to execute command inside EnvConfig
2019-04-17 22:33:16.354120: [debug] Finding out which packages are already installed
2019-04-17 22:33:16.354120: [debug] Run process: C:\Users\Mike Pilgrem\AppData\Local\Programs\stack\x86_64-windows\ghc-8.2.2\bin\ghc-pkg.exe --global --no-user-package-db dump --expand-pkgroot
2019-04-17 22:33:16.456721: [debug] Process finished in 89ms: C:\Users\Mike Pilgrem\AppData\Local\Programs\stack\x86_64-windows\ghc-8.2.2\bin\ghc-pkg.exe --global --no-user-package-db dump --expand-pkgroot
2019-04-17 22:33:16.456721: [debug] Ignoring package process due to wanting version 1.6.3.0 instead of 1.6.1.0
2019-04-17 22:33:16.456721: [debug] Ignoring package haskeline due to wanting version 0.7.4.3 instead of 0.7.4.0
2019-04-17 22:33:16.456721: [debug] Ignoring package Cabal due to wanting version 2.4.0.1 instead of 2.0.1.0
2019-04-17 22:33:16.456721: [debug] Run process: C:\Users\Mike Pilgrem\AppData\Local\Programs\stack\x86_64-windows\ghc-8.2.2\bin\ghc-pkg.exe --user --no-user-package-db --package-db C:\sr\snapshots\1addba98\pkgdb dump --expand-pkgroot
2019-04-17 22:33:16.629768: [debug] Process finished in 167ms: C:\Users\Mike Pilgrem\AppData\Local\Programs\stack\x86_64-windows\ghc-8.2.2\bin\ghc-pkg.exe --user --no-user-package-db --package-db C:\sr\snapshots\1addba98\pkgdb dump --expand-pkgroot
2019-04-17 22:33:16.629768: [debug] Run process: C:\Users\Mike Pilgrem\AppData\Local\Programs\stack\x86_64-windows\ghc-8.2.2\bin\ghc-pkg.exe --user --no-user-package-db --package-db "C:\\Users\\Mike Pilgrem\\Documents\\Code\\GitHub\\stack\\.stack-work\\install\\62732513\\pkgdb" dump --expand-pkgroot
2019-04-17 22:33:16.726914: [debug] Process finished in 91ms: C:\Users\Mike Pilgrem\AppData\Local\Programs\stack\x86_64-windows\ghc-8.2.2\bin\ghc-pkg.exe --user --no-user-package-db --package-db "C:\\Users\\Mike Pilgrem\\Documents\\Code\\GitHub\\stack\\.stack-work\\install\\62732513\\pkgdb" dump --expand-pkgroot
2019-04-17 22:33:16.726914: [debug] Constructing the build plan
2019-04-17 22:33:16.726914: [debug] Parsing cabal file for Cabal (from Hackage)
2019-04-17 22:33:16.726914: [debug] Parsing cabal file for process (from Hackage)
2019-04-17 22:33:16.726914: [debug] Parsing cabal file for amazonka (from Hackage)
2019-04-17 22:33:16.742540: [debug] Parsing cabal file for amazonka-core (from Hackage)
2019-04-17 22:33:16.742540: [debug] Parsing cabal file for bifunctors (from Hackage)
2019-04-17 22:33:16.758173: [debug] Parsing cabal file for comonad (from Hackage)
2019-04-17 22:33:16.758173: [debug] Parsing cabal file for cabal-doctest (from Hackage)
2019-04-17 22:33:16.758173: [debug] Parsing cabal file for distributive (from Hackage)
2019-04-17 22:33:16.758173: [debug] Parsing cabal file for conduit-extra (from Hackage)
2019-04-17 22:33:16.773805: [debug] Parsing cabal file for network (from Hackage)
2019-04-17 22:33:16.776827: [debug] Parsing cabal file for streaming-commons (from Hackage)
2019-04-17 22:33:16.776827: [debug] Parsing cabal file for typed-process (from Hackage)
2019-04-17 22:33:16.776827: [debug] Parsing cabal file for http-client (from Hackage)
2019-04-17 22:33:16.776827: [debug] Parsing cabal file for http-conduit (from Hackage)
2019-04-17 22:33:16.776827: [debug] Parsing cabal file for http-client-tls (from Hackage)
2019-04-17 22:33:16.776827: [debug] Parsing cabal file for connection (from Hackage)
2019-04-17 22:33:16.776827: [debug] Parsing cabal file for socks (from Hackage)
2019-04-17 22:33:16.776827: [debug] Parsing cabal file for tls (from Hackage)
2019-04-17 22:33:16.792469: [debug] Parsing cabal file for x509-system (from Hackage)
2019-04-17 22:33:16.792469: [debug] Parsing cabal file for lens (from Hackage)
2019-04-17 22:33:16.792469: [debug] Parsing cabal file for free (from Hackage)
2019-04-17 22:33:16.792469: [debug] Parsing cabal file for profunctors (from Hackage)
2019-04-17 22:33:16.808094: [debug] Parsing cabal file for semigroupoids (from Hackage)
2019-04-17 22:33:16.823718: [debug] Parsing cabal file for kan-extensions (from Hackage)
2019-04-17 22:33:16.823718: [debug] Parsing cabal file for adjunctions (from Hackage)
2019-04-17 22:33:16.823718: [debug] Parsing cabal file for xml-conduit (from Hackage)
2019-04-17 22:33:16.823718: [debug] Parsing cabal file for amazonka-s3 (from Hackage)
2019-04-17 22:33:16.823718: [debug] Parsing cabal file for cryptonite-conduit (from Hackage)
2019-04-17 22:33:16.823718: [debug] Parsing cabal file for html-conduit (from Hackage)
2019-04-17 22:33:16.823718: [debug] Parsing cabal file for rio (from Hackage)
2019-04-17 22:33:16.823718: [debug] Parsing cabal file for unliftio (from Hackage)
2019-04-17 22:33:16.839340: [debug] Parsing cabal file for optparse-simple (from Hackage)
2019-04-17 22:33:16.839340: [debug] Parsing cabal file for gitrev (from Hackage)
2019-04-17 22:33:16.839340: [debug] Parsing cabal file for optparse-applicative (from Hackage)
2019-04-17 22:33:16.839340: [debug] Parsing cabal file for hackage-security (from Hackage)
2019-04-17 22:33:16.839340: [debug] Parsing cabal file for hpack (from Hackage)
2019-04-17 22:33:16.839340: [debug] Parsing cabal file for persistent (from Hackage)
2019-04-17 22:33:16.839340: [debug] Parsing cabal file for http-api-data (from Hackage)
2019-04-17 22:33:16.839340: [debug] Parsing cabal file for monad-logger (from Hackage)
2019-04-17 22:33:16.854964: [debug] Parsing cabal file for stm-chans (from Hackage)
2019-04-17 22:33:16.854964: [debug] Parsing cabal file for persistent-sqlite (from Hackage)
2019-04-17 22:33:16.854964: [debug] Parsing cabal file for persistent-template (from Hackage)
2019-04-17 22:33:16.854964: [debug] Parsing cabal file for rio-orphans (from Hackage)
2019-04-17 22:33:16.854964: [debug] Parsing cabal file for zip-archive (from Hackage)
2019-04-17 22:33:16.854964: [debug] Parsing cabal file for echo (from Hackage)
2019-04-17 22:33:16.854964: [debug] Parsing cabal file for extra (from Hackage)
2019-04-17 22:33:16.854964: [debug] Parsing cabal file for githash (from Hackage)
2019-04-17 22:33:16.854964: [debug] Parsing cabal file for mustache (from Hackage)
2019-04-17 22:33:16.870588: [debug] Parsing cabal file for cmdargs (from Hackage)
2019-04-17 22:33:16.877243: [debug] Parsing cabal file for either (from Hackage)
2019-04-17 22:33:16.878242: [debug] Parsing cabal file for open-browser (from Hackage)
2019-04-17 22:33:16.879241: [debug] Parsing cabal file for project-template (from Hackage)
2019-04-17 22:33:16.881253: [warn] WARNING: Ignoring lens's bounds on Cabal (>=1.10 && <2.3); using Cabal-2.4.0.1.
Reason: trusting snapshot over cabal file dependency information.
2019-04-17 22:33:16.881253: [debug] Checking if we are going to build multiple executables with the same name
2019-04-17 22:33:16.882240: [debug] Executing the build plan
2019-04-17 22:33:16.884259: [debug] SELECT "id","platform_ghc_dir","compiler","cabal_version","package_key","options_hash","library" FROM "precompiled_cache" WHERE "platform_ghc_dir"=? AND "compiler"=? AND "cabal_version"=? AND "package_key"=? AND "options_hash"=?; [PersistText "x86_64-windows\\",PersistText "ghc-8.2.2",PersistText "2.0.1.0",PersistText "56285baa11d679521837e1f41311a1aeafa522e7637d408d3decd99c083edba1,2254",PersistByteString "\146\CAN\219y\136\153\130\247\199\196\DC3\185\161\167\156R\SO\129\SI\160'{\191\STX\a\161\155\157\203\196|r"]
2019-04-17 22:33:16.888241: [debug] SELECT "id","platform_ghc_dir","compiler","cabal_version","package_key","options_hash","library" FROM "precompiled_cache" WHERE "platform_ghc_dir"=? AND "compiler"=? AND "cabal_version"=? AND "package_key"=? AND "options_hash"=?; [PersistText "x86_64-windows\\",PersistText "ghc-8.2.2",PersistText "2.0.1.0",PersistText "815cfe49244b1491aab57bd9dc094745d85933445dd440ed7d61d88bcfda1e4c,1211",PersistByteString "\v\156\130'\DC2\207/\255\211Z\149\155\133\DC2\136\156\DC1m]x&m\147K\171\SYN\GS\148\EOT\150\&2\206"]
2019-04-17 22:33:16.919506: [debug] SELECT "id","directory","type","pkg_src","active","path_env_var" FROM "config_cache" WHERE "directory"=? AND "type"=?; [PersistText "C:\\Users\\Mike Pilgrem\\AppData\\Local\\Temp\\stack75124\\network-2.6.3.6\\",PersistText "config"]
2019-04-17 22:33:16.919506: [debug] UPDATE "config_cache" SET "active"=? WHERE ("directory"=?) AND ("type"=?); [PersistBool False,PersistText "C:\\Users\\Mike Pilgrem\\AppData\\Local\\Temp\\stack75124\\network-2.6.3.6\\",PersistText "config"]
2019-04-17 22:33:16.919506: [info] network > configure
2019-04-17 22:33:16.935132: [debug] Run process within C:\Users\Mike Pilgrem\AppData\Local\Temp\stack75124\network-2.6.3.6\: C:\Users\Mike Pilgrem\AppData\Local\Programs\stack\x86_64-windows\ghc-8.2.2\bin\ghc-8.2.2.exe --make -odir "C:\\Users\\Mike Pilgrem\\AppData\\Local\\Temp\\stack75124\\network-2.6.3.6\\.stack-work\\dist\\5c8418a7\\setup" -hidir "C:\\Users\\Mike Pilgrem\\AppData\\Local\\Temp\\stack75124\\network-2.6.3.6\\.stack-work\\dist\\5c8418a7\\setup" -i -i. -package=Cabal-2.0.1.0 -clear-package-db -global-package-db -package-db=C:\sr\snapshots\1addba98\pkgdb "C:\\Users\\Mike Pilgrem\\AppData\\Local\\Temp\\stack75124\\network-2.6.3.6\\Setup.hs" C:\sr\setup-exe-src\setup-shim-Z6RU0evB.hs -main-is StackSetupShim.mainOverride -o "C:\\Users\\Mike Pilgrem\\AppData\\Local\\Temp\\stack75124\\network-2.6.3.6\\.stack-work\\dist\\5c8418a7\\setup\\setup" -threaded
2019-04-17 22:33:17.055526: [debug] SELECT "id","directory","type","pkg_src","active","path_env_var" FROM "config_cache" WHERE "directory"=? AND "type"=?; [PersistText "C:\\Users\\Mike Pilgrem\\AppData\\Local\\Temp\\stack75124\\process-1.6.3.0\\",PersistText "config"]
2019-04-17 22:33:17.209231: [info] network > [1 of 2] Compiling Main ( C:\Users\Mike Pilgrem\AppData\Local\Temp\stack75124\network-2.6.3.6\Setup.hs, C:\Users\Mike Pilgrem\AppData\Local\Temp\stack75124\network-2.6.3.6\.stack-work\dist\5c8418a7\setup\Main.o )
2019-04-17 22:33:17.726227: [info] network > [2 of 2] Compiling StackSetupShim ( C:\sr\setup-exe-src\setup-shim-Z6RU0evB.hs, C:\Users\Mike Pilgrem\AppData\Local\Temp\stack75124\network-2.6.3.6\.stack-work\dist\5c8418a7\setup\StackSetupShim.o )
2019-04-17 22:33:18.042680: [info] network > Linking C:\Users\Mike Pilgrem\AppData\Local\Temp\stack75124\network-2.6.3.6\.stack-work\dist\5c8418a7\setup\setup.exe ...
2019-04-17 22:33:32.485816: [debug] Process finished in 15556ms: C:\Users\Mike Pilgrem\AppData\Local\Programs\stack\x86_64-windows\ghc-8.2.2\bin\ghc-8.2.2.exe --make -odir "C:\\Users\\Mike Pilgrem\\AppData\\Local\\Temp\\stack75124\\network-2.6.3.6\\.stack-work\\dist\\5c8418a7\\setup" -hidir "C:\\Users\\Mike Pilgrem\\AppData\\Local\\Temp\\stack75124\\network-2.6.3.6\\.stack-work\\dist\\5c8418a7\\setup" -i -i. -package=Cabal-2.0.1.0 -clear-package-db -global-package-db -package-db=C:\sr\snapshots\1addba98\pkgdb "C:\\Users\\Mike Pilgrem\\AppData\\Local\\Temp\\stack75124\\network-2.6.3.6\\Setup.hs" C:\sr\setup-exe-src\setup-shim-Z6RU0evB.hs -main-is StackSetupShim.mainOverride -o "C:\\Users\\Mike Pilgrem\\AppData\\Local\\Temp\\stack75124\\network-2.6.3.6\\.stack-work\\dist\\5c8418a7\\setup\\setup" -threaded
2019-04-17 22:33:32.563973: [debug] Run process within C:\Users\Mike Pilgrem\AppData\Local\Temp\stack75124\network-2.6.3.6\: C:\Users\Mike Pilgrem\AppData\Local\Temp\stack75124\network-2.6.3.6\.stack-work\dist\5c8418a7\setup\setup.exe --builddir=.stack-work\dist\5c8418a7 configure --user --package-db=clear --package-db=global --package-db=C:\sr\snapshots\1addba98\pkgdb --libdir=C:\sr\snapshots\1addba98\lib --bindir=C:\sr\snapshots\1addba98\bin --datadir=C:\sr\snapshots\1addba98\share --libexecdir=C:\sr\snapshots\1addba98\libexec --sysconfdir=C:\sr\snapshots\1addba98\etc --docdir=C:\sr\snapshots\1addba98\doc\network-2.6.3.6 --htmldir=C:\sr\snapshots\1addba98\doc\network-2.6.3.6 --haddockdir=C:\sr\snapshots\1addba98\doc\network-2.6.3.6 --dependency=base=base-4.10.1.0 --dependency=bytestring=bytestring-0.10.8.2 "--extra-include-dirs=C:\\Users\\Mike Pilgrem\\AppData\\Local\\Programs\\stack\\x86_64-windows\\msys2-20180531\\mingw64\\include" "--extra-lib-dirs=C:\\Users\\Mike Pilgrem\\AppData\\Local\\Programs\\stack\\x86_64-windows\\msys2-20180531\\mingw64\\lib" "--extra-lib-dirs=C:\\Users\\Mike Pilgrem\\AppData\\Local\\Programs\\stack\\x86_64-windows\\msys2-20180531\\mingw64\\bin" --exact-configuration --ghc-option=-fhide-source-paths
2019-04-17 22:33:36.874139: [info] network > Configuring network-2.6.3.6...
2019-04-17 22:33:41.202130: [warn] network > configure: WARNING: unrecognized options: --with-compiler
2019-04-17 22:33:43.508865: [info] network > configure: loading site script /usr/local/etc/config.site
2019-04-17 22:33:44.527413: [info] network > checking build system type... x86_64-w64-mingw32
2019-04-17 22:33:44.527413: [info] network > checking host system type... x86_64-w64-mingw32
2019-04-17 22:33:44.527413: [info] network > checking for gcc... C:\Users\Mike Pilgrem\AppData\Local\Programs\stack\X86_64~1\ghc-8.2.2\mingw\bin\gcc.exe
2019-04-17 22:33:45.862044: [info] network > checking whether the C compiler works... no
2019-04-17 22:33:45.931087: [warn] network > configure: error: in `/c/Users/Mike Pilgrem/AppData/Local/Temp/stack75124/network-2.6.3.6':
2019-04-17 22:33:45.931087: [warn] network > configure: error: C compiler cannot create executables
2019-04-17 22:33:45.931087: [warn] network > See `config.log' for more details
2019-04-17 22:33:46.617459: [debug] UPDATE "config_cache" SET "active"=? WHERE ("directory"=?) AND ("type"=?); [PersistBool False,PersistText "C:\\Users\\Mike Pilgrem\\AppData\\Local\\Temp\\stack75124\\process-1.6.3.0\\",PersistText "config"]
2019-04-17 22:33:46.617459: [info] process > configure
2019-04-17 22:33:46.633101: [debug] Run process within C:\Users\Mike Pilgrem\AppData\Local\Temp\stack75124\process-1.6.3.0\: C:\Users\Mike Pilgrem\AppData\Local\Programs\stack\x86_64-windows\ghc-8.2.2\bin\ghc-8.2.2.exe --make -odir "C:\\Users\\Mike Pilgrem\\AppData\\Local\\Temp\\stack75124\\process-1.6.3.0\\.stack-work\\dist\\5c8418a7\\setup" -hidir "C:\\Users\\Mike Pilgrem\\AppData\\Local\\Temp\\stack75124\\process-1.6.3.0\\.stack-work\\dist\\5c8418a7\\setup" -i -i. -package=Cabal-2.0.1.0 -clear-package-db -global-package-db -package-db=C:\sr\snapshots\1addba98\pkgdb "C:\\Users\\Mike Pilgrem\\AppData\\Local\\Temp\\stack75124\\process-1.6.3.0\\Setup.hs" C:\sr\setup-exe-src\setup-shim-Z6RU0evB.hs -main-is StackSetupShim.mainOverride -o "C:\\Users\\Mike Pilgrem\\AppData\\Local\\Temp\\stack75124\\process-1.6.3.0\\.stack-work\\dist\\5c8418a7\\setup\\setup" -threaded
2019-04-17 22:33:46.902673: [info] process > [1 of 2] Compiling Main ( C:\Users\Mike Pilgrem\AppData\Local\Temp\stack75124\process-1.6.3.0\Setup.hs, C:\Users\Mike Pilgrem\AppData\Local\Temp\stack75124\process-1.6.3.0\.stack-work\dist\5c8418a7\setup\Main.o )
2019-04-17 22:33:47.334123: [info] process > [2 of 2] Compiling StackSetupShim ( C:\sr\setup-exe-src\setup-shim-Z6RU0evB.hs, C:\Users\Mike Pilgrem\AppData\Local\Temp\stack75124\process-1.6.3.0\.stack-work\dist\5c8418a7\setup\StackSetupShim.o )
2019-04-17 22:33:47.650577: [info] process > Linking C:\Users\Mike Pilgrem\AppData\Local\Temp\stack75124\process-1.6.3.0\.stack-work\dist\5c8418a7\setup\setup.exe ...
2019-04-17 22:34:00.165752: [debug] Process finished in 13527ms: C:\Users\Mike Pilgrem\AppData\Local\Programs\stack\x86_64-windows\ghc-8.2.2\bin\ghc-8.2.2.exe --make -odir "C:\\Users\\Mike Pilgrem\\AppData\\Local\\Temp\\stack75124\\process-1.6.3.0\\.stack-work\\dist\\5c8418a7\\setup" -hidir "C:\\Users\\Mike Pilgrem\\AppData\\Local\\Temp\\stack75124\\process-1.6.3.0\\.stack-work\\dist\\5c8418a7\\setup" -i -i. -package=Cabal-2.0.1.0 -clear-package-db -global-package-db -package-db=C:\sr\snapshots\1addba98\pkgdb "C:\\Users\\Mike Pilgrem\\AppData\\Local\\Temp\\stack75124\\process-1.6.3.0\\Setup.hs" C:\sr\setup-exe-src\setup-shim-Z6RU0evB.hs -main-is StackSetupShim.mainOverride -o "C:\\Users\\Mike Pilgrem\\AppData\\Local\\Temp\\stack75124\\process-1.6.3.0\\.stack-work\\dist\\5c8418a7\\setup\\setup" -threaded
2019-04-17 22:34:00.167770: [debug] Run process within C:\Users\Mike Pilgrem\AppData\Local\Temp\stack75124\process-1.6.3.0\: C:\Users\Mike Pilgrem\AppData\Local\Temp\stack75124\process-1.6.3.0\.stack-work\dist\5c8418a7\setup\setup.exe --builddir=.stack-work\dist\5c8418a7 configure --user --package-db=clear --package-db=global --package-db=C:\sr\snapshots\1addba98\pkgdb --libdir=C:\sr\snapshots\1addba98\lib --bindir=C:\sr\snapshots\1addba98\bin --datadir=C:\sr\snapshots\1addba98\share --libexecdir=C:\sr\snapshots\1addba98\libexec --sysconfdir=C:\sr\snapshots\1addba98\etc --docdir=C:\sr\snapshots\1addba98\doc\process-1.6.3.0 --htmldir=C:\sr\snapshots\1addba98\doc\process-1.6.3.0 --haddockdir=C:\sr\snapshots\1addba98\doc\process-1.6.3.0 --dependency=Win32=Win32-2.5.4.1 --dependency=base=base-4.10.1.0 --dependency=deepseq=deepseq-1.4.3.0 --dependency=directory=directory-1.3.0.2 --dependency=filepath=filepath-1.4.1.2 "--extra-include-dirs=C:\\Users\\Mike Pilgrem\\AppData\\Local\\Programs\\stack\\x86_64-windows\\msys2-20180531\\mingw64\\include" "--extra-lib-dirs=C:\\Users\\Mike Pilgrem\\AppData\\Local\\Programs\\stack\\x86_64-windows\\msys2-20180531\\mingw64\\lib" "--extra-lib-dirs=C:\\Users\\Mike Pilgrem\\AppData\\Local\\Programs\\stack\\x86_64-windows\\msys2-20180531\\mingw64\\bin" --exact-configuration --ghc-option=-fhide-source-paths
2019-04-17 22:34:03.603932: [info] process > Configuring process-1.6.3.0...
2019-04-17 22:34:07.804442: [warn] process > configure: WARNING: unrecognized options: --with-compiler
2019-04-17 22:34:10.324674: [info] process > configure: loading site script /usr/local/etc/config.site
2019-04-17 22:34:10.411788: [info] process > checking for gcc... C:\Users\Mike Pilgrem\AppData\Local\Programs\stack\X86_64~1\ghc-8.2.2\mingw\bin\gcc.exe
2019-04-17 22:34:11.701670: [info] process > checking whether the C compiler works... no
2019-04-17 22:34:11.737738: [warn] process > configure: error: in `/c/Users/Mike Pilgrem/AppData/Local/Temp/stack75124/process-1.6.3.0':
2019-04-17 22:34:11.737738: [warn] process > configure: error: C compiler cannot create executables
2019-04-17 22:34:11.738723: [warn] process > See `config.log' for more details
2019-04-17 22:34:12.224703: [error]
-- While building package process-1.6.3.0 using:
C:\Users\Mike Pilgrem\AppData\Local\Temp\stack75124\process-1.6.3.0\.stack-work\dist\5c8418a7\setup\setup --builddir=.stack-work\dist\5c8418a7 configure --user --package-db=clear --package-db=global --package-db=C:\sr\snapshots\1addba98\pkgdb --libdir=C:\sr\snapshots\1addba98\lib --bindir=C:\sr\snapshots\1addba98\bin --datadir=C:\sr\snapshots\1addba98\share --libexecdir=C:\sr\snapshots\1addba98\libexec --sysconfdir=C:\sr\snapshots\1addba98\etc --docdir=C:\sr\snapshots\1addba98\doc\process-1.6.3.0 --htmldir=C:\sr\snapshots\1addba98\doc\process-1.6.3.0 --haddockdir=C:\sr\snapshots\1addba98\doc\process-1.6.3.0 --dependency=Win32=Win32-2.5.4.1 --dependency=base=base-4.10.1.0 --dependency=deepseq=deepseq-1.4.3.0 --dependency=directory=directory-1.3.0.2 --dependency=filepath=filepath-1.4.1.2 "--extra-include-dirs=C:\\Users\\Mike Pilgrem\\AppData\\Local\\Programs\\stack\\x86_64-windows\\msys2-20180531\\mingw64\\include" "--extra-lib-dirs=C:\\Users\\Mike Pilgrem\\AppData\\Local\\Programs\\stack\\x86_64-windows\\msys2-20180531\\mingw64\\lib" "--extra-lib-dirs=C:\\Users\\Mike Pilgrem\\AppData\\Local\\Programs\\stack\\x86_64-windows\\msys2-20180531\\mingw64\\bin" --exact-configuration --ghc-option=-fhide-source-paths
Process exited with code: ExitFailure 77
-- While building package network-2.6.3.6 using:
C:\Users\Mike Pilgrem\AppData\Local\Temp\stack75124\network-2.6.3.6\.stack-work\dist\5c8418a7\setup\setup --builddir=.stack-work\dist\5c8418a7 configure --user --package-db=clear --package-db=global --package-db=C:\sr\snapshots\1addba98\pkgdb --libdir=C:\sr\snapshots\1addba98\lib --bindir=C:\sr\snapshots\1addba98\bin --datadir=C:\sr\snapshots\1addba98\share --libexecdir=C:\sr\snapshots\1addba98\libexec --sysconfdir=C:\sr\snapshots\1addba98\etc --docdir=C:\sr\snapshots\1addba98\doc\network-2.6.3.6 --htmldir=C:\sr\snapshots\1addba98\doc\network-2.6.3.6 --haddockdir=C:\sr\snapshots\1addba98\doc\network-2.6.3.6 --dependency=base=base-4.10.1.0 --dependency=bytestring=bytestring-0.10.8.2 "--extra-include-dirs=C:\\Users\\Mike Pilgrem\\AppData\\Local\\Programs\\stack\\x86_64-windows\\msys2-20180531\\mingw64\\include" "--extra-lib-dirs=C:\\Users\\Mike Pilgrem\\AppData\\Local\\Programs\\stack\\x86_64-windows\\msys2-20180531\\mingw64\\lib" "--extra-lib-dirs=C:\\Users\\Mike Pilgrem\\AppData\\Local\\Programs\\stack\\x86_64-windows\\msys2-20180531\\mingw64\\bin" --exact-configuration --ghc-option=-fhide-source-paths
Process exited with code: ExitFailure 77
Progress 2/57
Interesting. I tried again to reproduce this today, and I noticed this in my output:
checking for gcc... C:\Users\MICHAE~1\Desktop\STACKP~1\X86_64~1\GHC-86~1.4\lib\../mingw/bin\gcc.exe
Notice how the paths being used by the configure
script on my system are using 8.3 format without any spaces. I don't know what would lead to this difference. Any thoughts?
I'm still tempted to treat this as a documentation issue. I can't guarantee any more time on trying to debug this, but if you'd like to try to get deeper into this issue, my next step would be to look at the output from:
stack unpack process-1.6.5.0
cd process-1.6.5.0
echo 'resolver: ghc-8.6.4 > stack.yaml
stack build --verbose --cabal-verbose
I agree that this is a documentation issue. After some further research, I discovered:
Cabal
library seems to make use of getShortPathName
(ccProgShort <- getShortPathName ccProg
- http://hackage.haskell.org/package/Cabal-2.4.1.0/docs/src/Distribution.Simple.html) as a work around for autoconf
being fussy about filenames. getShortPathName
will not return a short path name if one does not exist but will return the long path name (https://docs.microsoft.com/en-us/windows/desktop/api/fileapi/nf-fileapi-getshortpathnamew).>fsutil 8dot3name query
The registry state is: 1 (Disable 8dot3 name creation on all volumes).
\Mike Pilgrem
folder (extract - the blank to the left of the folder name means no short name):
>dir C:\Users /X
28/01/2018 09:24
- On Windows, it is possible to give a folder a short name using the `fsutil file setshortname <filename> <shortname>` command (https://docs.microsoft.com/en-us/windows-server/administration/windows-commands/fsutil-file). In my case, I think I will stick with re-assigning the `local-programs-path`.
I have proposed a pull request #4798, targeting the stable branch, with documentation changes.
Thanks! Closing now that #4798 is merged.
I can't build the current stack master (last commit is abf4ca08706e02256a500e507ff7ec47c21e55c8, a clean clone from GitHub) with stack (version is: Version 1.9.3, Git revision 40cf7b37526b86d1676da82167ea8758a854953b (6211 commits) x86_64 hpack-0.31.1, a clean download of the binary) on Windows 10. It always fails at the
process-1.6.3.0
step. For example:Given the reference in the error message above to
gcc
, in case it is relevant: