nrk / redis-lua

A Lua client library for the redis key value storage system.
MIT License
731 stars 239 forks source link

problem with lib socket in lua 5.1 #46

Closed EvandroLG closed 8 years ago

EvandroLG commented 8 years ago

redis-lua doesn't seem to be working with Lua 5.1.4, version that I'm using in my project. when I try to connect, I get this error:

error loading module 'socket.core' from file '/usr/local/lib/lua/5.1/socket/core.so':
    dlopen(/usr/local/lib/lua/5.1/socket/core.so, 2): Symbol not found: _luaL_prepbuffsize
  Referenced from: /usr/local/lib/lua/5.1/socket/core.so
  Expected in: flat namespace
 in /usr/local/lib/lua/5.1/socket/core.so
stack traceback:
    [C]: ?
    [C]: in function 'require'
    /usr/local/share/lua/5.1/socket.lua:12: in main chunk
    [C]: in function 'require'
    /usr/local/share/lua/5.1/redis.lua:793: in function 'create_connection'
    /usr/local/share/lua/5.1/redis.lua:836: in function 'connect'
    stdin:1: in main chunk
    [C]: ?
EvandroLG commented 8 years ago

I fixed my problem, re-compiling the luasocket library. thanks ;)