Fri Dec 18 23:40:29 CET 1998
> I've been wondering how one can make Erlang scripts/binaries?
> Something that can be then run as
Dan Sahlin once wrote a little thing to accomplish this (hello
Dan where are you ?).
You also have the 'erl_call' command which is intended to be
used from shell scripts. It makes it possible to start/stop
Erlang, evaluate one/many functions etc. Whatever the Erlang
function in question returns is also returned from erl_call.
Run: erl_call without any switches and a short help with all
the switches is printed.
erl_call -s -a my_module -sname my_node
The -s switch will start a node, -sname specifies the node name: my_node
This will take a few sec. but next time you call erl_call the node
is already started and the communication is really fast. To stop the
node use the -q switch.
> Another question: Erlang seems to compile to P-code, right?
No, JAM code. See the link to Ericsson CSLab and look under
publications to get more info about JAM and BEAM.
> Are there any native compilers?
beam: used to (?) compile to C
gerl: a prototype which implements a subset of Erlang can be
found from the Links page.
Also at the links page, there is a link to Uni.of.Montreal.
Not sure if they compile to native code though.
> Or something like python freeze, that allows to pack up
> the whole system in one (admittingly huge) binary and sent
> it someone?
More information about the erlang-questions