[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: luasocket problem
- From: David Burgess <dburgess@...>
- Date: Sun, 20 Nov 2005 00:55:29 +1100
I am not a FreeBSD user, but I think you have guessed correctly,
you need different linker flags, luaL_checknumber is in the lua executable
(or .so) depending on how you have built lua.
How did you build lua?
What version of lua, I guess 5.0.2 ?
DB
On 11/19/05, Manfred Lotz <manfred.lotz@arcor.de> wrote:
> Hi all,
> I'm running FreeBSD and I downloaded luasocket-2.0-beta3. I could build
> it and when trying a small test script I got errors.
>
> Here's how I did proceed:
>
> I set the following variables:
> export LUA_INIT="@$PWD/compat-5.1r2/compat-5.1.lua"
> export LUA_PATH='?.lua;lua/?.lua'
> export LUA_CPATH='?.so'
>
> The script contains just one line:
> socket = require("socket");
>
>
> When running it I get:
>
>
> lua: ...d/dl/luasocket-2.0-beta3/compat-5.1r2/compat-5.1.lua:66: ./lsocket.so:
> Undefined symbol "luaL_checknumber" stack traceback:
> [C]: in function `assert'
> ...d/dl/luasocket-2.0-beta3/compat-5.1r2/compat-5.1.lua:66: in
> function `require' lua/socket.lua:13: in function `f'
> ...d/dl/luasocket-2.0-beta3/compat-5.1r2/compat-5.1.lua:77: in
> function `require' test.lua:2: in main chunk
> [C]: ?
>
>
>
> What can I do? At least 'objdump -R lsocket.so | grep checkn' shows:
>
> 000037d3 R_386_PC32 luaL_checknumber
> 00003c16 R_386_PC32 luaL_checknumber
> 000052fa R_386_PC32 luaL_checknumber
> 00005cb4 R_386_PC32 luaL_checknumber
> 00005e30 R_386_PC32 luaL_checknumber
> 00005ed3 R_386_PC32 luaL_checknumber
> 000063f0 R_386_PC32 luaL_checknumber
> 00006730 R_386_PC32 luaL_checknumber
> 00006883 R_386_PC32 luaL_checknumber
> 00006998 R_386_PC32 luaL_checknumber
>
>
> Do I need different linker flags? I used makefile.Linux to build it. I
> only added -I/usr/local/include to make the compiler happy.
>
>
> --
> Manfred
>