Add a note about byte-code executables (#108)
This commit is contained in:
parent
65dfec6a41
commit
a677a6077e
|
@ -193,11 +193,16 @@ need to specify the entry point. Given an ``executable`` stanza with ``(name
|
|||
bytecode executable which requires ``ocamlrun`` to run and ``<name>.bc.js`` is a
|
||||
JavaScript generated using js_of_ocaml.
|
||||
|
||||
Note that in case native compilation is not available, ``<name>.exe`` will in
|
||||
fact be a custom byte-code executable. Custom in the sense of ``ocamlc
|
||||
-custom``, meaning that it is a native executable that embeds the ``ocamlrun``
|
||||
virtual machine as well as the byte code. As such you can always rely on
|
||||
``<name>.exe`` being available.
|
||||
Note that in case native compilation is not available, ``<name>.exe``
|
||||
will in fact be a custom byte-code executable. Custom in the sense of
|
||||
``ocamlc -custom``, meaning that it is a native executable that embeds
|
||||
the ``ocamlrun`` virtual machine as well as the byte code. As such you
|
||||
can always rely on ``<name>.exe`` being available. Moreover, it is
|
||||
usually preferable to use ``<name>.exe`` in custom rules or when
|
||||
calling the executable by hand. This is because running a byte-code
|
||||
executable often requires loading shared libraries that are locally
|
||||
built, and so requires additional setup such as setting specific
|
||||
environment variables and jbuilder doesn't do at the moment.
|
||||
|
||||
Native compilation is considered not available when there is no ``ocamlopt``
|
||||
binary at the same place as where ``ocamlc`` was found, or when there is a
|
||||
|
|
Loading…
Reference in New Issue