我要安装System.FilePath.Find模块。我尝试使用
cabal install FileManip
但失败了:
Resolving dependencies...
Configuring FileManip-0.3.3.1...
Preprocessing library FileManip-0.3.3.1...
Building FileManip-0.3.3.1...
[1 of 5] Compiling System.FilePath.Error ( System/FilePath/Error.hs, dist/build/System/FilePath/Error.o )
[2 of 5] Compiling System.FilePath.Manip ( System/FilePath/Manip.hs, dist/build/System/FilePath/Manip.o )
[3 of 5] Compiling System.FilePath.GlobPattern ( System/FilePath/GlobPattern.hs, dist/build/System/FilePath/GlobPattern.o )
[4 of 5] Compiling System.FilePath.Glob ( System/FilePath/Glob.hs, dist/build/System/FilePath/Glob.o )
[5 of 5] Compiling System.FilePath.Find ( System/FilePath/Find.hs, dist/build/System/FilePath/Find.o )
System/FilePath/Find.hs:174:20:
Not in scope: data constructor `State'
cabal: Error: some packages failed to install:
FileManip-0.3.3.1 failed during the building phase. The exception was:
ExitFailure 1
我做错了什么?
$ ghc --version
The Glorious Glasgow Haskell Compilation System, version 6.12.1
$ cabal --version
cabal-install version 0.8.0
using version 1.8.0.2 of the Cabal library
最佳答案
FileManip 软件包在 Hackage 上被标记为已过时,最后一个版本是 2010 年。
使用filemanip (小写)代替。它应该是最新的。
您可能还想升级您的 GHC。版本 6.12.1 是从 2009 年 12 月开始的。
关于haskell - 安装 System.FilePath.Find 时遇到问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/13098012/