1

I'm trying to run js_of_eliom, but it seems that it don't have ppx_deriving This is the message i got when i do a make:

js_of_eliom -ppx -c -package lwt -package js_of_ocaml.deriving -package js_of_ocaml.ppx  simple_pomodoro.eliom
Fatal error: exception Fl_package_base.No_such_package("js_of_ocaml.ppx", "")
make: *** [_client/simple_pomodoro.cmo] Error 2

And when i do an ocamlfind query js_of_ocaml.ppx i got this:

ocamlfind: Package `js_of_ocaml.ppx' not found

But i have installed the ppx_deriving, opam list shows it:

ppx_deriving           3.3  Type-driven code generation for OCaml >=4.02

I'm running in a mac osx with el capitan(10.11) Any idea why this is happening?

EDIT

Oh sorry i have the js_of_ocaml also installed, this what appears in my ocamlfind:

λ ~/ ocamlfind list | grep js_of_ocaml
js_of_ocaml         (version: 2.7)
js_of_ocaml.compiler (version: [distributed with js_of_ocaml])
js_of_ocaml.compiler.with_findlib (version: n/a)
js_of_ocaml.deriving (version: [distributed with js_of_ocaml])
js_of_ocaml.deriving.ppx (version: [distributed with js_of_ocaml])
js_of_ocaml.deriving.syntax (version: [distributed with js_of_ocaml])
js_of_ocaml.graphics (version: [distributed with js_of_ocaml])
js_of_ocaml.log     (version: [distributed with js_of_ocaml])
js_of_ocaml.ocamlbuild (version: [distributed with js_of_ocaml])
js_of_ocaml.syntax  (version: [distributed with js_of_ocaml])
js_of_ocaml.toplevel (version: [distributed with js_of_ocaml])
js_of_ocaml.tyxml   (version: [distributed with js_of_ocaml])
js_of_ocaml.weak    (version: [distributed with js_of_ocaml])
João Zeni
  • 21
  • 1
  • 3

2 Answers2

0

The ppx_deriving is a driver, that manages different derivers. By itself it doesn't provide any. You need to install the js_of_ocaml deriver, that is a part of js_of_ocaml package:

opam install js_of_ocaml

As a result you will have it:

$ ocamlfind list | grep js_of_ocaml.ppx
js_of_ocaml.ppx     (version: [distributed with js_of_ocaml])
js_of_ocaml.ppx.internal (version: [distributed with js_of_ocaml])
ivg
  • 34,431
  • 2
  • 35
  • 63
0

I found a solution to it in ocsigen issues report through github https://github.com/ocsigen/eliom/issues/251

I did this:

  • I have reinstall opam (v.1.2.2), re-init, install 4.02.3, utop & eliom. It was still not working. Then I installed deriving_ppx.3.0.0 as you already mentioned in SO, and now it is working fine. Thx !
João Zeni
  • 21
  • 1
  • 3