0
votes

I try to do some linear algebra calculating in OCaml. And I had installed Lacaml package. Knowing the slap package is more user friendly, I decided to use this package instead of Lacaml. I did install slap package successfully by typing "opam install slap". But when compiling a file by typing "ocamlfind ocamlc -linkpkg -package slap,slap.ppx -short-paths jacobi.ml", the error

"ocamlfind: Package `slap_ppx' not found" 

occurred. I has been trying a lot to deal with it, but can't. I has tried to make the package by hand. But a problem called

"File "ppx/ppx_slap.ml", line 21, characters 0-15:
Error: Unbound module Ast_helper" 

occurred. I had no idea the "Ast_helper" module is in which package.

Above is all descriptions about my problems. If someone had installed the slap, please help me.

2
are you sure that you didn't type slap_ppx? There should be slap.ppx. Besides, your command works for me. Maybe you should try to opam update and opam upgrade? - ivg

2 Answers

1
votes

I'm developing slap package. Your command works well for me, but opam sometimes fails to install packages. I have encountered broken dependency for slap on opam, but opam update and opam upgrade solves such problems. Maybe it's helpful for you. ppx_tools is not required for slap package because compiler-libs of OCaml 4.02 supports Ast_helper.

0
votes

The Ast_helper module is used in PPX development, so it makes sense that a PPX would require it, but I'm surprised that installation succeeded if this is the case. I believe that this module is included in the ppx_tools package, which may be installed with the command

opam update && opam install ppx_tools