Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Why can't pervasives.cmi be opened?

Tags:

ocaml

Installed Ocaml on my cygwin machine but simple compiles fail. Permissions are fine as you can see by the interaction below. OCAMLLIB is right; What is wrong?

$ cat t.ml

print_string "hi";

$ ocamlopt t.ml
>> Fatal error: cannot open pervasives.cmi
Fatal error: exception Misc.Fatal_error

$ echo $OCAMLLIB
/cygdrive/c/OCaml/lib

$ ls -l /cygdrive/c/OCaml/lib/pervasives.cmi
-rwxrwxrwx+ 1 Lyn None 15094 Oct  8 01:30 /cygdrive/c/OCaml/lib/pervasives.cmi
like image 649
Lyn Headley Avatar asked Mar 29 '13 22:03

Lyn Headley


1 Answers

A possible solution is to run this command in cygwin:

export OCAMLLIB=C:\\OCaml\\lib

The clue came from this message thread.

like image 111
Dave Newman Avatar answered Sep 28 '22 09:09

Dave Newman