Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ocamlnat crashes on startup #7254

Closed
vicuna opened this issue May 12, 2016 · 10 comments
Closed

ocamlnat crashes on startup #7254

vicuna opened this issue May 12, 2016 · 10 comments

Comments

@vicuna
Copy link

vicuna commented May 12, 2016

Original bug ID: 7254
Reporter: @hannesm
Assigned to: @mshinwell
Status: resolved (set by @mshinwell on 2017-03-10T14:56:00Z)
Resolution: duplicate
Priority: normal
Severity: text
Platform: UNIX
OS: FreeBSD
OS Version: CURRENT
Version: 4.03.0
Category: documentation
Monitored by: @diml @hcarty

Bug description

executing ./ocamlnat leads to exception:

    OCaml version 4.03.1+dev0-2016-04-25 - native toplevel

Fatal error: exception Cmi_format.Error(_)

Steps to reproduce

check out the 4.03 branch (525799b);
./configure ; gmake world.opt ; gmake ocamlnat
./ocamlnat

Additional information

I also tried trunk/master, and got the same result (a crashing ocamlnat)

@vicuna
Copy link
Author

vicuna commented May 12, 2016

Comment author: @hannesm

after doing a gmake bootstrap, I get a different error (can't find Topdirs):
OCaml version 4.03.1+dev0-2016-04-25 - native toplevel

File "none", line 1:
Warning 58: no cmx file was found in path for module Topdirs, and its interface was not compiled with -opaque

Fatal error: Opttoploop.dll_run /tmp/camlTOP3adce30.so: Undefined symbol "camlTopdirs"
Fatal error: exception Misc.Fatal_error

@vicuna
Copy link
Author

vicuna commented May 12, 2016

Comment author: @gasche

Note that ocamlnat is not officially supported: pull requests to fix it are welcome, but for now there is no guarantee that it will be working -- as you can observe. I think that Thomas "trefis" Refis would be the right person to ask to get it working again, or maybe Jérémie Dimino.

@vicuna
Copy link
Author

vicuna commented May 12, 2016

Comment author: @gasche

Also, before jumping to "ocamlnat development", I should have thought about the more likely issues. Have you tried setting "-I stdlib -nostdlib -noinit"? See the "runtop" target in the Makefile that I added for conveniently running a locally-built bytecode toplevel -- feel free to duplicate them into a runnattop target.

@vicuna
Copy link
Author

vicuna commented May 13, 2016

Comment author: @hannesm

the makefile target natruntop actually works (documentation about 'how to build and use ocamlnat' might help (sorry if there's some, I wasn't able to find any; did a git grep ocamlnat)?)

@vicuna
Copy link
Author

vicuna commented May 13, 2016

Comment author: @damiendoligez

I think you have to make install before you can run ocamlnat.

@vicuna
Copy link
Author

vicuna commented May 14, 2016

Comment author: @hannesm

@doligez as mentioned in my comment, make natruntop works.

Sorry for the noise, this issue can be closed.

@vicuna
Copy link
Author

vicuna commented May 14, 2016

Comment author: @gasche

I'm leaving the issue open because I want to document the fact that:

  • ocamlnat is not officially supported (pull requests are welcome), but
  • it can be run with "make natruntop" (I forgot about this target myself) from a source checkout, or just "./ocamlnat" after the distribution has been installed

@vicuna
Copy link
Author

vicuna commented Jul 13, 2016

Comment author: @alainfrisch

Reducing Severity, since this is only about documentation (of a non-supported tool!).

@vicuna
Copy link
Author

vicuna commented Mar 10, 2017

Comment author: @mshinwell

Superceded by #1096 which addresses the documentation issue.

@emillon
Copy link
Contributor

emillon commented Jan 26, 2021

If anyone's having the same issue, it can be caused by the presence of ~/.ocamlinit which is also interpreted by ocamlnat.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants