haskell - 无法成功安装plot Haskell

标签 haskell plot installation cabal-install hmatrix

我想在我的 Haskell 程序中做一些绘图,但是当我尝试安装绘图时出现以下错误。

Preprocessing library plot-0.2.3.4...

lib/Graphics/Rendering/Plot/Figure/Simple.hs:37:8:
    Could not find module ‘Numeric.Container’
    Use -v to see a list of the files searched for.

lib/Graphics/Rendering/Plot/Types.hs:25:8:
    Could not find module ‘Data.Packed.Vector’
    Use -v to see a list of the files searched for.

lib/Graphics/Rendering/Plot/Types.hs:26:8:
    Could not find module ‘Data.Packed.Matrix’
    Use -v to see a list of the files searched for.
cabal: Error: some packages failed to install:
plot-0.2.3.4 failed during the building phase. The exception was:
ExitFailure 1

已关注 this issue我将 hmatrix 更新到版本 0.17.0.1 但仍然遇到相同的错误。有什么想法吗?

最佳答案

您是使用 cabal 管理该项目,还是只是安装到全局包空间中?

我会转而使用cabalstack 来管理依赖项。 FWIW 我已经验证 plot-0.2.3.4 将使用堆栈解析器 lts-3.7hmatrix-0.16.1.5 进行编译,所以我不不认为这是 hmatrix 的问题。

如果您正在使用 cabal,请发布您的 cabal 文件,我们可以找出如何使其工作。否则,我建议创建一个堆栈项目,例如。

  • 运行堆栈新项目名称
  • 编辑 project-name.cabal 并将 plot 添加到 build-depends: 字段
  • 运行堆栈构建

关于haskell - 无法成功安装plot Haskell,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/33374575/

相关文章:

haskell - Haskell thunk 在评估方面是否可变?

haskell - 列表并行评估

python - 如何在Python中将一维C数组绘制为曲面

javascript - 如何使用外部 JavaScript 代码访问和更新 Bokeh 图或小部件?

python - 关闭科学记数法和全局偏移

scala - 1::List[Nothing] in foldLeft

haskell $!运算符和无限列表

C# 安装项目安装后运行

windows - 如何在 Windows 上安装 mongoDB?

wix - 在 WIX 安装程序中自定义对话框图像和横幅图像