I have installed opam and ocaml through Homebrew. When I run which Ocaml I get /Users/me/.opam/system/bin/ocaml
which opam however gives /usr/local/bin/opam. Is this normal? If so running utop gives me the error /Users/me/.opam/system/bin/utop' is not a bytecode executable file…Can anyone lend some help as to how to go about troubleshooting this?
Running which utop also gives /Users/me/.opam/system/bin/utop
Currently Running MacOS High Sierra. This is happening after an upgrade
You don’t specify how you installed opam and the like. Homebrew perhaps? Regardless, that’s important information. You’re also using a system switch, rather than an opam created switch, which isn’t really recommended.
Thank you for the reply. Unfortunately running opam switch 4.07.1 results in an error: [ERROR] No switch 4.07.1 is currently installed. Did you mean ‘opam switch
create 4.07.1’?
Installed switches are:
- system
Running opam switch create 4.07.1:
[ERROR] No compiler matching ‘4.07.1’ found, use ‘opam switch list-available’
to see what is available, or use ‘–packages’ to select packages
explicitly.
running opam switch list-available gives: Listing available compilers from repositories: default
[ERROR] No compiler matching 'ocaml-base-compiler.4.07.1' found, use 'opam
switch list-available' to see what is available, or use '--packages' to
select packages explicitly.
Is this mv command supposed to create a new directory? I see opam in /usr/local/bin/ as an executable. I can once again run the opam command but utop gives the error:
Fatal error: the file '/Users/me/.opam/system/bin/utop' is not a bytecode executable file