ocaml电池未绑定的toploop错误

时间:2016-03-01 08:00:10

标签: ocaml ocaml-batteries

我正在尝试按照Ubuntu 14.04中ropc / bap / INSTALL中给出的说明安装ropc https://github.com/pakt/ropc所需的bap。我已成功运行这些命令。

sudo apt-get install ocaml ocaml-native-compilers ocaml-findlib camlidl \
libocamlgraph-ocaml-dev libextlib-ocaml-dev binutils-dev automake \
libcamomile-ocaml-dev otags libpcre3-dev camlp4-extra bison flex

现在,当我在bap目录中创建它时,我得到以下Unbound模块toploop错误,这似乎是电池和ocaml之间的兼容性问题。我该如何解决这个问题?请参阅图片了解更多详情

Image uploaded

我读到我应该在某处添加 -I + compiler-libs 。但到底在哪里?我没有使用ocaml的经验,我只是想成功构建ropc。

1 个答案:

答案 0 :(得分:0)

我尝试编译pact / ropc项目,我只能确认问题。

虽然ocaml配置成功,但编译显示未定义的错误:

Error: Some fatal warnings were triggered (2 occurrences)
../Makefile.shared:84: recipe for target 'nat.cmo' failed
make[2]: *** [nat.cmo] Error 2
make[2]: Leaving directory '/home/strobel/tmp/ropc/bap-0.4/bigint-3.12/otherlibs/num'
Makefile:5: recipe for target 'all' failed
make[1]: *** [all] Error 2
make[1]: Leaving directory '/home/strobel/tmp/ropc/bap-0.4/bigint-3.12'
Makefile:356: recipe for target 'all-recursive' failed

ROPC中使用的bap组件在opam中可用,但ROPC不是,它显示出bitrot的迹象。为github项目打开了3个问题,讲述了编译问题。

我有一个非常好的配置ocaml设置,包直接来自opam(非常最新的版本),我的方法是看它是否会在这里编译。

怎么办?

也许卸载你的debian ocaml包,用opam重新开始。也有可能安装旧的ocaml版本,所以也许可以及时回到3.12 ocaml版本。但是在相应的版本中获得所需的软件包可能并不那么容易,opam很新。这将是一个高级的ocaml调试工作IMO。