[erlang-questions] Luerl - Lua in Erlang
Robert Virding
robert.virding@REDACTED
Mon Feb 20 15:18:52 CET 2012
3> You need to compile both the .yrl and .xrl file.
If you start erlang in the luerl top directory with :
erl -pa ebin
...
1> yecc:file("src/luerl_parse").
src/luerl_parse.yrl: Warning: conflicts: 2 shift/reduce, 0 reduce/reduce
{ok,"src/luerl_parse.erl"}
2> leex:file("src/luerl_scan").
{ok,"src/luerl_scan.erl"}
3> make:all([load]).
...
up_to_date
4>
- The -pa ebin is to make sure it finds all the .beam files in ebin.
- Both yecc and leex by default put their generated .erl files in the same directory as the .yrl and .xrl source files.
- The Emakefile contains data for compiling all the .erl files in src and putting them in ebin.
I added lines in .gitignore to exclude the generated luerl_parse/scan.erl files as small changes in the source files can cause big changes in the .erl files. That was probably a mistake and I will revert it next commit.
Robert
----- Original Message -----
> On 2/20/12 3:38 AM, Robert Virding wrote:
> > ----- Original Message -----
>
> > > On 19 February 2012 00:32, Robert Virding
> > > <robert.virding@REDACTED> wrote:
> >
>
> > > > Report bugs and missing features.
> > >
> >
>
> I don't get it to run. I tried basically:
> mkdir ebin
> erl
> 1> yecc:file("luerl_parse.yrl").
> erl -make
> erl
> 2> luerl:eval(<<"Hello Robert!">>).
> ** exception error: undefined function luerl_scan:string/1
> in function luerl:eval/1
> Need I compile the .xrl?
> > What is also needed is a good interface between erlang and Lua.
>
> What requirements would a good interface meet?
> Henning
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20120220/45ddc804/attachment.htm>
More information about the erlang-questions
mailing list