Closed ghost closed 7 years ago
Which version of ocaml are you using and how was it installed ?
OK, I see it is 4.04.0, but how was it installed ?
Since the error messages refer to /usr/lib/ocaml/
, I assume it is a system switch.
My experience with system switches is that they are generally unreliable (the system package manager can bump versions without telling opam, especially on arch were updates are frequent).
I would suggest using a local switch, opam switch 4.04.0
(build and compile locally).
Could it be a problem with the ocaml
package on Archlinux that should be compiled with -fPIC
but isn't? In any case, this looks like an environment misconfiguration rather than an upstream bug.
Thanks guys for taking the time to help out with this issue. I have worked around the issue as per @let-def 's suggestion by using opam switch 4.04.0
. I was able to install those packages without any problem on a different machine with the same version of ocaml though.
I tried to install the following packages on Archlinux.
$ CHECK_IF_PREINSTALLED=false opam install merlin utop ocp-indent
This is the output.
The error messages suggest recompiling with -fPIC. It might be similar to this issue of the Haskell build tool stack which also needs recomiling with -fPIC. This issue has been fixed in ghc 8.0.2 release which gets installed when I run
stack setup
. https://github.com/commercialhaskell/stack/issues/2712So the question is how should I fix this issue in opam? I am new to the ocaml ecosystem.