让Haskell的hsenv在Ubuntu 13上工作

时间:2013-05-01 20:49:24

标签: ubuntu haskell sudo

我正在努力让GHC在Ubuntu上工作。做了以下事情:

sudo apt-get install ghc
sudo apt-get install cabal-install
cabal update
cabal install hsenv

然后我尝试创建一个hsenv环境并获得以下内容:

xx@xx-VirtualBox:~/scm/t1$ hsenv
Creating Virtual Haskell directory structure
Installing GHC
Initializing GHC Package database at /home/xx/scm/t1/.hsenv/ghc_pkg_db
Copying necessary packages from original GHC package database
  Failed to copy optional package ghc-binary from system's GHC: 
    /usr/bin/ghc-pkg process failed with status 1
  Using user-wide (~/.cabal/packages) Hackage download cache directory
Installing cabal config at /home/xx/scm/t1/.hsenv/cabal/config
Installing activate script
Installing cabal wrapper using /home/xx/scm/t1/.hsenv/cabal/config at /home/xx/scm/t1/.hsenv/bin/cabal
Skipping 'cabal update' step, Hackage download cache already downloaded
  to ~/.cabal/packages/. You can update it manually with 'cabal update'
  (from inside or outside the virtual environment).

关键信息在这里:

  

无法从系统的GHC复制可选包ghc-binary:

如何解决此问题?这似乎是目前唯一的障碍。

1 个答案:

答案 0 :(得分:0)

这是this line引起的hsenv错误。看来,在最近的GHC版本中,此软件包已重命名为binary

但是hsenv还是一个过时的项目,建议使用新的cabal-installstack