#include #include #include #include "posixtz.h" #define MYNAME "posixtz" static int Pfrom_file(lua_State *L) { const char *s = luaL_checkstring(L, 1); lua_pushstring(L, posix_tz(s)); return 1; } static const luaL_reg R[] = { {"from_file", Pfrom_file}, NULL, NULL }; LUALIB_API int luaopen_posixtz_core(lua_State *L) { luaL_register(L,MYNAME,R); return 1; }