mirror of
https://github.com/mlua-rs/mlua
synced 2026-06-08 16:05:43 +00:00
Support LUA_LIB_NAME in module mode for windows.
In this mode we will link with the particular lua library.
This commit is contained in:
@@ -14,10 +14,7 @@ pub struct luaL_Reg {
|
||||
pub func: lua_CFunction,
|
||||
}
|
||||
|
||||
#[cfg_attr(
|
||||
all(windows, feature = "module", feature = "vendored"),
|
||||
link(name = "lua51", kind = "raw-dylib")
|
||||
)]
|
||||
#[cfg_attr(all(windows, raw_dylib), link(name = "lua51", kind = "raw-dylib"))]
|
||||
extern "C" {
|
||||
pub fn luaL_register(L: *mut lua_State, libname: *const c_char, l: *const luaL_Reg);
|
||||
#[link_name = "luaL_getmetafield"]
|
||||
@@ -60,10 +57,7 @@ extern "C" {
|
||||
pub const LUA_NOREF: c_int = -2;
|
||||
pub const LUA_REFNIL: c_int = -1;
|
||||
|
||||
#[cfg_attr(
|
||||
all(windows, feature = "module", feature = "vendored"),
|
||||
link(name = "lua51", kind = "raw-dylib")
|
||||
)]
|
||||
#[cfg_attr(all(windows, raw_dylib), link(name = "lua51", kind = "raw-dylib"))]
|
||||
extern "C" {
|
||||
pub fn luaL_ref(L: *mut lua_State, t: c_int) -> c_int;
|
||||
pub fn luaL_unref(L: *mut lua_State, t: c_int, r#ref: c_int);
|
||||
|
||||
Reference in New Issue
Block a user