lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


On 27 August 2013 04:21, David Demelier <demelier.david@gmail.com> wrote:
> 2013/8/27 steve donovan <steve.j.donovan@gmail.com>:
>> On Tue, Aug 27, 2013 at 8:44 AM, Vadim Peretokin <vperetokin@gmail.com> wrote:
>>> Hm... yes... why create such, well, spam?
>>
>> It's not a bad idea, but a little script that says 'luarocks install
>> $1 && luarocks show $1' is easy to write.
>>
>
> I just wanted to try the most used and basic module luasocket, it didn't work:
>
> Using http://www.luarocks.org/repositories/rocks/luasocket-2.0.2-4.src.rock...
> switching to 'build' mode
> Archive:  /tmp/luarocks_luarocks-rock-luasocket-2.0.2-4-8227/luasocket-2.0.2-4.src.rock
>  extracting: luasocket-2.0.2-4.rockspec
>  extracting: luasocket-2.0.2.tar.gz
> cd src; gmake all
> gmake[1]: Entering directory
> `/tmp/luarocks_luasocket-2.0.2-4-5133/luasocket-2.0.2/src'
> gcc -O2 -fPIC -DLUASOCKET_DEBUG -I/usr/local/include/lua52   -c -o
> luasocket.o luasocket.c
> In file included from luasocket.c:31:
> auxiliar.h:38: error: expected declaration specifiers or '...' before 'luaL_reg'
> luasocket.c:50: error: expected '=', ',', ';', 'asm' or
> '__attribute__' before 'mod'
> luasocket.c:62: error: expected '=', ',', ';', 'asm' or
> '__attribute__' before 'func'
> luasocket.c: In function 'base_open':
> luasocket.c:92: error: 'func' undeclared (first use in this function)
> luasocket.c:92: error: (Each undeclared identifier is reported only once
> luasocket.c:92: error: for each function it appears in.)
> luasocket.c: In function 'luaopen_socket_core':
> luasocket.c:116: error: 'mod' undeclared (first use in this function)
> gmake[1]: *** [luasocket.o] Error 1
> gmake[1]: Leaving directory
> `/tmp/luarocks_luasocket-2.0.2-4-5133/luasocket-2.0.2/src'
> gmake: *** [all] Error 2
>
> Error: Build error: Failed building.
>
> Of course, the problem comes more from the author, which should not
> use luaL_reg. I thought LuaSocket was ported to 5.2 ?

It was ported but it was not released yet. As a workaround, the latest
release candidate, LuaRocks 3.0rc1, is available at the secondary
repository for unreleased code:

luarocks install luasocket --server=http://luarocks.org/repositories/rocks-scm/

-- Hisham