diff options
author | Pixel <pixel@nobis-crew.org> | 2009-05-15 18:22:00 -0700 |
---|---|---|
committer | Pixel <pixel@nobis-crew.org> | 2009-05-15 18:22:00 -0700 |
commit | e20675412a5d4aadd861517b40ca200d9b605225 (patch) | |
tree | a36832a68907811bb65e3c95ed64c5d53d3379cb /lib/LuaHandle.cc | |
parent | 1bd9d06b327531887f663d9c0222be6091ad65a9 (diff) |
Making UCL optionnal.
Diffstat (limited to 'lib/LuaHandle.cc')
-rw-r--r-- | lib/LuaHandle.cc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/LuaHandle.cc b/lib/LuaHandle.cc index e2b621e..29af5d7 100644 --- a/lib/LuaHandle.cc +++ b/lib/LuaHandle.cc @@ -72,8 +72,10 @@ class sLuaHandle : public Base { static int get_nb_buffer(lua_State * L); static int zlib_inflate(lua_State * L); static int zlib_deflate(lua_State * L); +#ifdef HAVE_UCL static int ucl_compress(lua_State * L); static int ucl_decompress(lua_State * L); +#endif private: static int read(lua_State * L, int); static int write(lua_State * L, int); @@ -583,6 +585,7 @@ int sLuaHandle::zlib_deflate(lua_State * __L) { return 1; } +#ifdef HAVE_UCL int sLuaHandle::ucl_compress(lua_State * __L) { Lua * L = Lua::find(__L); int n = L->gettop(); @@ -622,6 +625,7 @@ int sLuaHandle::ucl_decompress(lua_State * __L) { return 1; } +#endif int sLuaHandle::seek(lua_State * __L) { Lua * L = Lua::find(__L); @@ -861,6 +865,8 @@ void LuaHandle::pushconstruct(Lua * L) { L->declarefunc("zlib_inflate", sLuaHandle::zlib_inflate); L->declarefunc("zlib_deflate", sLuaHandle::zlib_deflate); +#ifdef HAVE_UCL L->declarefunc("ucl_compress", sLuaHandle::ucl_compress); L->declarefunc("ucl_decompress", sLuaHandle::ucl_decompress); +#endif } |