Renamed luaL_reg to luaL_Reg
The original struct name is luaL_Reg, but Lua v5.1 had a `typedef luaL_reg luaL_Reg`, which in v5.2 was removed and as a result breaking the build in Awesome which uses luaL_reg version exclusively. Signed-off-by: Arvydas Sidorenko <asido4@gmail.com>
This commit is contained in:
parent
ec5ef67404
commit
d61cdb86c9
|
@ -124,8 +124,8 @@ luaA_typename(lua_State *L, int idx)
|
|||
|
||||
void
|
||||
luaA_openlib(lua_State *L, const char *name,
|
||||
const struct luaL_reg methods[],
|
||||
const struct luaL_reg meta[])
|
||||
const struct luaL_Reg methods[],
|
||||
const struct luaL_Reg meta[])
|
||||
{
|
||||
luaL_newmetatable(L, name); /* 1 */
|
||||
lua_pushvalue(L, -1); /* dup metatable 2 */
|
||||
|
@ -206,8 +206,8 @@ luaA_class_setup(lua_State *L, lua_class_t *class,
|
|||
lua_class_checker_t checker,
|
||||
lua_class_propfunc_t index_miss_property,
|
||||
lua_class_propfunc_t newindex_miss_property,
|
||||
const struct luaL_reg methods[],
|
||||
const struct luaL_reg meta[])
|
||||
const struct luaL_Reg methods[],
|
||||
const struct luaL_Reg meta[])
|
||||
{
|
||||
/* Create the object metatable */
|
||||
lua_newtable(L);
|
||||
|
|
|
@ -79,12 +79,12 @@ void luaA_class_connect_signal_from_stack(lua_State *, lua_class_t *, const char
|
|||
void luaA_class_disconnect_signal_from_stack(lua_State *, lua_class_t *, const char *, int);
|
||||
void luaA_class_emit_signal(lua_State *, lua_class_t *, const char *, int);
|
||||
|
||||
void luaA_openlib(lua_State *, const char *, const struct luaL_reg[], const struct luaL_reg[]);
|
||||
void luaA_openlib(lua_State *, const char *, const struct luaL_Reg[], const struct luaL_Reg[]);
|
||||
void luaA_class_setup(lua_State *, lua_class_t *, const char *, lua_class_t *,
|
||||
lua_class_allocator_t, lua_class_collector_t,
|
||||
lua_class_checker_t,
|
||||
lua_class_propfunc_t, lua_class_propfunc_t,
|
||||
const struct luaL_reg[], const struct luaL_reg[]);
|
||||
const struct luaL_Reg[], const struct luaL_Reg[]);
|
||||
|
||||
void luaA_class_add_property(lua_class_t *, const char *,
|
||||
lua_class_propfunc_t, lua_class_propfunc_t, lua_class_propfunc_t);
|
||||
|
|
2
dbus.c
2
dbus.c
|
@ -789,7 +789,7 @@ luaA_dbus_disconnect_signal(lua_State *L)
|
|||
return 0;
|
||||
}
|
||||
|
||||
const struct luaL_reg awesome_dbus_lib[] =
|
||||
const struct luaL_Reg awesome_dbus_lib[] =
|
||||
{
|
||||
{ "request_name", luaA_dbus_request_name },
|
||||
{ "release_name", luaA_dbus_release_name },
|
||||
|
|
|
@ -142,7 +142,7 @@ luaA_keygrabber_isrunning(lua_State *L)
|
|||
return 1;
|
||||
}
|
||||
|
||||
const struct luaL_reg awesome_keygrabber_lib[] =
|
||||
const struct luaL_Reg awesome_keygrabber_lib[] =
|
||||
{
|
||||
{ "run", luaA_keygrabber_run },
|
||||
{ "stop", luaA_keygrabber_stop },
|
||||
|
|
18
luaa.c
18
luaa.c
|
@ -48,15 +48,15 @@
|
|||
#include "common/backtrace.h"
|
||||
|
||||
#ifdef WITH_DBUS
|
||||
extern const struct luaL_reg awesome_dbus_lib[];
|
||||
extern const struct luaL_Reg awesome_dbus_lib[];
|
||||
#endif
|
||||
extern const struct luaL_reg awesome_keygrabber_lib[];
|
||||
extern const struct luaL_reg awesome_mousegrabber_lib[];
|
||||
extern const struct luaL_reg awesome_root_lib[];
|
||||
extern const struct luaL_reg awesome_mouse_methods[];
|
||||
extern const struct luaL_reg awesome_mouse_meta[];
|
||||
extern const struct luaL_reg awesome_screen_methods[];
|
||||
extern const struct luaL_reg awesome_screen_meta[];
|
||||
extern const struct luaL_Reg awesome_keygrabber_lib[];
|
||||
extern const struct luaL_Reg awesome_mousegrabber_lib[];
|
||||
extern const struct luaL_Reg awesome_root_lib[];
|
||||
extern const struct luaL_Reg awesome_mouse_methods[];
|
||||
extern const struct luaL_Reg awesome_mouse_meta[];
|
||||
extern const struct luaL_Reg awesome_screen_methods[];
|
||||
extern const struct luaL_Reg awesome_screen_meta[];
|
||||
|
||||
/** Path to config file */
|
||||
static char *conffile;
|
||||
|
@ -521,7 +521,7 @@ void
|
|||
luaA_init(xdgHandle* xdg)
|
||||
{
|
||||
lua_State *L;
|
||||
static const struct luaL_reg awesome_lib[] =
|
||||
static const struct luaL_Reg awesome_lib[] =
|
||||
{
|
||||
{ "quit", luaA_quit },
|
||||
{ "exec", luaA_exec },
|
||||
|
|
4
mouse.c
4
mouse.c
|
@ -225,7 +225,7 @@ luaA_mouse_object_under_pointer(lua_State *L)
|
|||
return 0;
|
||||
}
|
||||
|
||||
const struct luaL_reg awesome_mouse_methods[] =
|
||||
const struct luaL_Reg awesome_mouse_methods[] =
|
||||
{
|
||||
{ "__index", luaA_mouse_index },
|
||||
{ "__newindex", luaA_mouse_newindex },
|
||||
|
@ -233,7 +233,7 @@ const struct luaL_reg awesome_mouse_methods[] =
|
|||
{ "object_under_pointer", luaA_mouse_object_under_pointer },
|
||||
{ NULL, NULL }
|
||||
};
|
||||
const struct luaL_reg awesome_mouse_meta[] =
|
||||
const struct luaL_Reg awesome_mouse_meta[] =
|
||||
{
|
||||
{ NULL, NULL }
|
||||
};
|
||||
|
|
|
@ -123,7 +123,7 @@ luaA_mousegrabber_isrunning(lua_State *L)
|
|||
return 1;
|
||||
}
|
||||
|
||||
const struct luaL_reg awesome_mousegrabber_lib[] =
|
||||
const struct luaL_Reg awesome_mousegrabber_lib[] =
|
||||
{
|
||||
{ "run", luaA_mousegrabber_run },
|
||||
{ "stop", luaA_mousegrabber_stop },
|
||||
|
|
|
@ -99,14 +99,14 @@ luaA_button_set_button(lua_State *L, button_t *b)
|
|||
void
|
||||
button_class_setup(lua_State *L)
|
||||
{
|
||||
static const struct luaL_reg button_methods[] =
|
||||
static const struct luaL_Reg button_methods[] =
|
||||
{
|
||||
LUA_CLASS_METHODS(button)
|
||||
{ "__call", luaA_button_new },
|
||||
{ NULL, NULL }
|
||||
};
|
||||
|
||||
static const struct luaL_reg button_meta[] =
|
||||
static const struct luaL_Reg button_meta[] =
|
||||
{
|
||||
LUA_OBJECT_META(button)
|
||||
LUA_CLASS_META
|
||||
|
|
|
@ -1648,7 +1648,7 @@ client_checker(client_t *c)
|
|||
void
|
||||
client_class_setup(lua_State *L)
|
||||
{
|
||||
static const struct luaL_reg client_methods[] =
|
||||
static const struct luaL_Reg client_methods[] =
|
||||
{
|
||||
LUA_CLASS_METHODS(client)
|
||||
{ "get", luaA_client_get },
|
||||
|
@ -1657,7 +1657,7 @@ client_class_setup(lua_State *L)
|
|||
{ NULL, NULL }
|
||||
};
|
||||
|
||||
static const struct luaL_reg client_meta[] =
|
||||
static const struct luaL_Reg client_meta[] =
|
||||
{
|
||||
LUA_OBJECT_META(client)
|
||||
LUA_CLASS_META
|
||||
|
|
|
@ -554,14 +554,14 @@ luaA_drawin_refresh(lua_State *L)
|
|||
void
|
||||
drawin_class_setup(lua_State *L)
|
||||
{
|
||||
static const struct luaL_reg drawin_methods[] =
|
||||
static const struct luaL_Reg drawin_methods[] =
|
||||
{
|
||||
LUA_CLASS_METHODS(drawin)
|
||||
{ "__call", luaA_drawin_new },
|
||||
{ NULL, NULL }
|
||||
};
|
||||
|
||||
static const struct luaL_reg drawin_meta[] =
|
||||
static const struct luaL_Reg drawin_meta[] =
|
||||
{
|
||||
LUA_OBJECT_META(drawin)
|
||||
LUA_CLASS_META
|
||||
|
|
|
@ -203,14 +203,14 @@ luaA_key_set_key(lua_State *L, keyb_t *k)
|
|||
void
|
||||
key_class_setup(lua_State *L)
|
||||
{
|
||||
static const struct luaL_reg key_methods[] =
|
||||
static const struct luaL_Reg key_methods[] =
|
||||
{
|
||||
LUA_CLASS_METHODS(key)
|
||||
{ "__call", luaA_key_new },
|
||||
{ NULL, NULL }
|
||||
};
|
||||
|
||||
static const struct luaL_reg key_meta[] =
|
||||
static const struct luaL_Reg key_meta[] =
|
||||
{
|
||||
LUA_OBJECT_META(key)
|
||||
LUA_CLASS_META
|
||||
|
|
|
@ -406,14 +406,14 @@ luaA_tag_get_screen(lua_State *L, tag_t *tag)
|
|||
void
|
||||
tag_class_setup(lua_State *L)
|
||||
{
|
||||
static const struct luaL_reg tag_methods[] =
|
||||
static const struct luaL_Reg tag_methods[] =
|
||||
{
|
||||
LUA_CLASS_METHODS(tag)
|
||||
{ "__call", luaA_tag_new },
|
||||
{ NULL, NULL }
|
||||
};
|
||||
|
||||
static const struct luaL_reg tag_meta[] =
|
||||
static const struct luaL_Reg tag_meta[] =
|
||||
{
|
||||
LUA_OBJECT_META(tag)
|
||||
LUA_CLASS_META
|
||||
|
|
|
@ -121,14 +121,14 @@ LUA_OBJECT_EXPORT_PROPERTY(timer, atimer_t, started, lua_pushboolean)
|
|||
void
|
||||
timer_class_setup(lua_State *L)
|
||||
{
|
||||
static const struct luaL_reg timer_methods[] =
|
||||
static const struct luaL_Reg timer_methods[] =
|
||||
{
|
||||
LUA_CLASS_METHODS(timer)
|
||||
{ "__call", luaA_timer_new },
|
||||
{ NULL, NULL }
|
||||
};
|
||||
|
||||
static const struct luaL_reg timer_meta[] =
|
||||
static const struct luaL_Reg timer_meta[] =
|
||||
{
|
||||
LUA_OBJECT_META(timer)
|
||||
LUA_CLASS_META
|
||||
|
|
|
@ -351,12 +351,12 @@ LUA_OBJECT_EXPORT_PROPERTY(window, window_t, border_width, lua_pushnumber)
|
|||
void
|
||||
window_class_setup(lua_State *L)
|
||||
{
|
||||
static const struct luaL_reg window_methods[] =
|
||||
static const struct luaL_Reg window_methods[] =
|
||||
{
|
||||
{ NULL, NULL }
|
||||
};
|
||||
|
||||
static const struct luaL_reg window_meta[] =
|
||||
static const struct luaL_Reg window_meta[] =
|
||||
{
|
||||
{ "struts", luaA_window_struts },
|
||||
{ "buttons", luaA_window_buttons },
|
||||
|
|
2
root.c
2
root.c
|
@ -287,7 +287,7 @@ luaA_root_wallpaper(lua_State *L)
|
|||
return 1;
|
||||
}
|
||||
|
||||
const struct luaL_reg awesome_root_lib[] =
|
||||
const struct luaL_Reg awesome_root_lib[] =
|
||||
{
|
||||
{ "buttons", luaA_root_buttons },
|
||||
{ "keys", luaA_root_keys },
|
||||
|
|
4
screen.c
4
screen.c
|
@ -662,14 +662,14 @@ luaA_screen_count(lua_State *L)
|
|||
return 1;
|
||||
}
|
||||
|
||||
const struct luaL_reg awesome_screen_methods[] =
|
||||
const struct luaL_Reg awesome_screen_methods[] =
|
||||
{
|
||||
{ "count", luaA_screen_count },
|
||||
{ "__index", luaA_screen_module_index },
|
||||
{ NULL, NULL }
|
||||
};
|
||||
|
||||
const struct luaL_reg awesome_screen_meta[] =
|
||||
const struct luaL_Reg awesome_screen_meta[] =
|
||||
{
|
||||
{ "add_signal", luaA_screen_add_signal },
|
||||
{ "connect_signal", luaA_screen_connect_signal },
|
||||
|
|
Loading…
Reference in New Issue