我按照“Yesod 快速入门指南”在 Windows 10 中安装 Yesod。但是,当我发出stack build
命令时,它失败了。
环境
- 视窗 10(64 位)
stack-0.1.5
(适用于 Windows10 64 位)- 没有 Haskell 平台
我执行了这些命令
- stack new my-project yesod-sqlite && cd my-project
- 堆栈安装 yesod-bin cabal-install --install-ghc
- 堆栈设置
- 堆栈构建 <--- 发生错误
在“stack build”命令中,软件包安装已完成。但是,当它构建项目时,发生了错误。
命令提示符
>stack build
Setting codepage to UTF-8 (65001) to ensure correct output from GHC
my-project-0.0.0: build
Preprocessing library my-project-0.0.0...
In-place registering my-project-0.0.0...
Preprocessing executable 'my-project' for my-project-0.0.0...
Linking .stack-work\dist\x86_64-windows\Cabal-1.22.4.0\build\my-project\my-project.exe ...
ghc.exe: could not execute: C:\Users\xxxxx\AppData\Local\Programs\stack\x86_64-windows\ghc-7.10.2\lib/../mingw/bin/gcc.exe
-- While building package my-project-0.0.0 using:
C:\Users\xxxxx\AppData\Roaming\local\bin\stack-0.1.5.0\setup-exe-cache\setup-Simple-Cabal-1.22.4.0-x86_64-windows-ghc-7.10.2.exe --builddir=.stack-work\dist\x86_64-windows\Cabal-1.22.4.0\ build lib:my-project exe:my-project --ghc-options -ddump-hi -ddump-to-file
Process exited with code: ExitFailure 1