aboutsummaryrefslogtreecommitdiff
path: root/common/lua/lualib.h
diff options
context:
space:
mode:
authorNipun Garg2019-03-09 02:41:35 +0530
committerEugene Sandulenko2019-08-13 10:18:02 +0200
commitc1f029c6dcd606b3dbe8e3952ac55f89968ab6c4 (patch)
tree251016525019b20ca6c41a95d4a584483724daee /common/lua/lualib.h
parentf019afa94a4638e6132551a570ce3b1d67b62b54 (diff)
downloadscummvm-rg350-c1f029c6dcd606b3dbe8e3952ac55f89968ab6c4.tar.gz
scummvm-rg350-c1f029c6dcd606b3dbe8e3952ac55f89968ab6c4.tar.bz2
scummvm-rg350-c1f029c6dcd606b3dbe8e3952ac55f89968ab6c4.zip
COMMON: Move Lua into Common and make it into...
an engine feature
Diffstat (limited to 'common/lua/lualib.h')
-rw-r--r--common/lua/lualib.h53
1 files changed, 53 insertions, 0 deletions
diff --git a/common/lua/lualib.h b/common/lua/lualib.h
new file mode 100644
index 0000000000..830f6a0894
--- /dev/null
+++ b/common/lua/lualib.h
@@ -0,0 +1,53 @@
+/*
+** $Id$
+** Lua standard libraries
+** See Copyright Notice in lua.h
+*/
+
+
+#ifndef lualib_h
+#define lualib_h
+
+#include "lua.h"
+
+
+/* Key to file-handle type */
+#define LUA_FILEHANDLE "FILE*"
+
+
+#define LUA_COLIBNAME "coroutine"
+LUALIB_API int (luaopen_base) (lua_State *L);
+
+#define LUA_TABLIBNAME "table"
+LUALIB_API int (luaopen_table) (lua_State *L);
+
+#define LUA_IOLIBNAME "io"
+LUALIB_API int (luaopen_io) (lua_State *L);
+
+#define LUA_OSLIBNAME "os"
+LUALIB_API int (luaopen_os) (lua_State *L);
+
+#define LUA_STRLIBNAME "string"
+LUALIB_API int (luaopen_string) (lua_State *L);
+
+#define LUA_MATHLIBNAME "math"
+LUALIB_API int (luaopen_math) (lua_State *L);
+
+#define LUA_DBLIBNAME "debug"
+LUALIB_API int (luaopen_debug) (lua_State *L);
+
+#define LUA_LOADLIBNAME "package"
+LUALIB_API int (luaopen_package) (lua_State *L);
+
+
+/* open all previous libraries */
+LUALIB_API void (luaL_openlibs) (lua_State *L);
+
+
+
+#ifndef lua_assert
+#define lua_assert(x) ((void)0)
+#endif
+
+
+#endif