Error when installing ocamlfind with ocamljava
Closed this issue · 4 comments
antoine1fr commented
Hi,
I've just installed ocamljava on opam 1.2.0 with the following commands:
opam remote add ocj http://opam.ocamljava.org
opam switch ocamljava-2.0-alpha2
eval `opam config env`
When trying to install ocamlfind I get the following error listing:
Building ocamlfind.1.5.5:
./configure -bindir /Users/antoine/.opam/ocamljava-2.0-alpha2/bin -sitelib /Users/antoine/.opam/ocamljava-2.0-alpha2/lib -mandir /Users/antoine/.opam/ocamljava-2.0-alpha2/man -config /Users/antoine/.opam/ocamljava-2.0-alpha2/lib/findlib.conf
make all
make opt
make install
[ERROR] The compilation of ocamlfind.1.5.5 failed.
Removing ocamlfind.1.5.5.
ocamlfind remove bytes
./configure -bindir /Users/antoine/.opam/ocamljava-2.0-alpha2/bin -sitelib /Users/antoine/.opam/ocamljava-2.0-alpha2/lib -mandir /Users/antoine/.opam/ocamljava-2.0-alpha2/man -config /Users/antoine/.opam/ocamljava-2.0-alpha2/lib/findlib.conf
make uninstall
#=== ERROR while installing ocamlfind.1.5.5 ===================================#
# opam-version 1.2.0
# os darwin
# command make all
# path /Users/antoine/.opam/ocamljava-2.0-alpha2/build/ocamlfind.1.5.5
# compiler ocamljava-2.0-alpha2
# exit-code 2
# env-file /Users/antoine/.opam/ocamljava-2.0-alpha2/build/ocamlfind.1.5.5/ocamlfind-6629-6d07ae.env
# stdout-file /Users/antoine/.opam/ocamljava-2.0-alpha2/build/ocamlfind.1.5.5/ocamlfind-6629-6d07ae.out
# stderr-file /Users/antoine/.opam/ocamljava-2.0-alpha2/build/ocamlfind.1.5.5/ocamlfind-6629-6d07ae.err
### stdout ###
# ...[truncated]
# ocamlc -I +compiler-libs -custom -o ocamlfind -g findlib.cma unix.cma \
# ocaml_args.cmo frontend.cmo
# if [ "false" = "true" ]; then \
# cp topfind.ml.in topfind.ml; \
# else \
# sed -e '/PPXOPT_BEGIN/,/PPXOPT_END/ d' topfind.ml.in \
# > topfind.ml ; \
# fi
# ocamlc -I +compiler-libs -c topfind.mli
# ocamlc -I +compiler-libs -g -c topfind.ml
### stderr ###
# File "itest-aux/ppx.ml", line 1, characters 0-25:
# Error: Unbound value Toploop.preprocess_phrase
# Makefile:160: depend: No such file or directory
# File "topfind.ml", line 1:
# Error: The files /Users/antoine/.opam/ocamljava-2.0-alpha2/lib/ocaml/compiler-libs/toploop.cmi
# and /Users/antoine/.opam/ocamljava-2.0-alpha2/lib/ocaml/compiler-libs/parsetree.cmi
# make inconsistent assumptions over interface Warnings
# make[1]: *** [topfind.cmo] Error 2
# make: *** [all] Error 2
Here is my config:
- OS X 10.10
- opam 1.2.0
- java 1.8.0_25-b17
Do you have any idea where the error could come from?
Thanks
pron commented
👍
xclerc commented
Indeed, you have to use a patched version of ocamlfind.
From the opam repository, you can install a draft vesion
through opam install ocamlfind-ocj
. This draft is based
on version 1.4.0, and will be updated to the last version
in OCaml-JAva alpha3 (hopefully available this month).
antoine1fr commented
Thanks for your answer! I'll try this ASAP. :)
xclerc commented
The new 2.0-alpha3 version comes with a new ocamlfind
package (version 1.5.5), available under the name ocj-ocamlfind
.