Load luabins library into Auto4 Lua environment

This commit is contained in:
Niels Martin Hansen 2014-04-24 22:57:23 +02:00
parent 057a223b38
commit 18f55eaebf
2 changed files with 5 additions and 0 deletions

View File

@ -14,6 +14,7 @@ LIBS := -L../libaegisub -laegisub $(LIBS)
LIBS += $(LIBS_GL) $(LIBS_PTHREAD) $(LIBS_WX) $(LIBS_FREETYPE)
LIBS += $(LIBS_FONTCONFIG) $(LIBS_FFTW3) $(LIBS_UCHARDET) $(LIBS_BOOST)
LIBS += $(LIBS_ICU) $(LIBS_LUA)
LIBS += ../vendor/luabins/libluabins.a
ifeq (yes, $(BUILD_DARWIN))
SRC += osx_utils.mm retina_helper.mm

View File

@ -307,6 +307,9 @@ namespace {
int luaopen_lpeg (lua_State *L);
// Forward-declaration for luabins library (not in any public header)
extern "C" int luaopen_luabins(lua_State * L);
namespace Automation4 {
int regex_init(lua_State *L);
@ -377,6 +380,7 @@ namespace Automation4 {
push_value(L, luaopen_package); lua_call(L, 0, 0);
push_value(L, luaopen_string); lua_call(L, 0, 0);
push_value(L, luaopen_table); lua_call(L, 0, 0);
push_value(L, luaopen_luabins); lua_call(L, 0, 0);
_stackcheck.check_stack(0);
// dofile and loadfile are replaced with include