install error with `ocamlfind`
idkjs opened this issue · comments
Alain Armand commented
Happy New Year!
I am trying to run this devkit. When I run opam install devkit
I get the following error referencing ocamlfind
. Any idea on what might be causing this?
ENV:
➜ ~ opam --version
2.0.5
➜ ~ macenv
ProductName: Mac OS X
ProductVersion: 10.15.2
BuildVersion: 19C57
yarn version: 1.21.1
node version: v13.3.0
➜ ~
~ opam install ocamlfind
The following actions will be performed:
∗ install ocamlfind 1.8.1
<><> Gathering sources ><><><><><><><><><> 🐫
[ocamlfind.1.8.1] found in cache
<><> Processing actions <><><><><><><><><> 🐫
[ERROR] The compilation of ocamlfind failed
at
"/Users/prisc_000/.opam/opam-init/hooks/sandbox.sh
build make all".
#=== ERROR while compiling ocamlfind.1.8.1 ==#
# context 2.0.5 | macos/x86_64 | ocaml-system.4.07.1 | https://opam.ocaml.org#b394cb53
# path ~/.opam/default/.opam-switch/build/ocamlfind.1.8.1
# command ~/.opam/opam-init/hooks/sandbox.sh build make all
# exit-code 2
# env-file ~/.opam/log/ocamlfind-28636-d2d111.env
# output-file ~/.opam/log/ocamlfind-28636-d2d111.out
### output ###
# [...]
# USE_CYGPATH="0"; \
# export USE_CYGPATH; \
# cat topfind_rd1.p | \
# ../../tools/patch '@SITELIB@' '/Users/prisc_000/.opam/default/lib' \
# >topfind
# ocamlc -I +compiler-libs -opaque -c num_top_printers.mli
# File "num_top_printers.mli", line 1:
# Error: /usr/local/lib/ocaml/nat.cmi
# is not a compiled interface for this version of OCaml.
# It seems to be for an older version of OCaml.
# make[1]: *** [num_top_printers.cmi] Error 2
# make: *** [all] Error 2
<><> Error report <><><><><><><><><><><><> 🐫
┌─ The following actions failed
│ λ build ocamlfind 1.8.1
└─
╶─ No changes have been performed
➜ ~
Thank you.
ygrek commented
# path ~/.opam/default/.opam-switch/build/ocamlfind.1.8.1
...
# Error: /usr/local/lib/ocaml/nat.cmi
this means you have opam switch in ~/.opam and some other unrelated ocaml files in /usr/local/lib/ocaml. It is advised to not have any ocaml bits installed outside of opam (unless you really want it and know what you are doing).
Alain Armand commented