从源安装 haskell-platform 时出错

Error when installing haskell-platform from source

我需要从源文件安装 haskell 平台,以便按照说明安装 Ubuntu 所需的 cabal、ghc 和其他库。

当我尝试使用以下命令安装 haskell 平台时:

./platform.sh /home/myuser/haskell/ghc-7.10.2-x86_64-unknown-linux-deb7.tar.bz2 -j 3

我收到以下错误:

***
*** Building hptool
***
Building hptool-0.1...
Preprocessing executable 'hptool' for hptool-0.1...
***
*** Running hptool
***
Error when running Shake build system:
* 3
Error, file does not exist and no rule available:
  3

而且我没有发现任何人有同样的错误。我下载的haskell平台版本是haskell-platform-7.10.2-a

使用 ./platform.sh 脚本时,您不能传递 -j 3.

这样的构建选项

像这样手动构建和 运行 hptool:

cd hptool
cabal sandbox init
cabal install -j3

cd ..
./hptool/.cabal-sandbox/bin/hptool PATH-TO-GHC-BINDIST SHAKE-TARGET

运行 不带参数的 hptool 获取 SHAKE-TARGET 的有效值列表。