Re: Advice request to build C functions in a library for Lua5.1
[
Date Prev][
Date Next][
Thread Prev][
Thread Next]
[
Date Index]
[
Thread Index]
- Subject: Re: Advice request to build C functions in a library for Lua5.1
- From: Crystal Jewels <crystal.jewels@...>
- Date: 2007年10月25日 13:43:12 -0700 (PDT)
FAO Alex
Yes, thank you I had already removed -llua and -llualib after consulting
however I did not obtain any advantage and so left them in. The error remained.
I accept that doing this results in a much tighter library with a smaller footprint and thank you for your advice.
Currently I still experience a failure using require with a reported failure to index.
Thanks
C
Alex Queiroz <asandroq@gmail.com> wrote:
Hallo,
On 10/25/07, Crystal Jewels wrote:
>
> // compile as:
> // gcc mylib.c -shared
-L/usr/local/lua5.1/lib -I/usr/local/lua5.1/include
> // -llua -llualib -lm -ldl -o mylib.so
>
You should not link your extensions with the Lua library.
Instead, link the Lua interpreter in way that makes it exports its
symbols.
Cheers,
--
-alex
http://www.ventonegro.org/
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com