mlua icon indicating copy to clipboard operation
mlua copied to clipboard

Support LuaJIT 2.0.5 for bytecode incompatibility reasons

Open brandonros opened this issue 3 years ago • 3 comments

Kind of a big ask so I 100% understand why you wouldn't want to do this

I forked https://github.com/brandonros/mlua and https://github.com/brandonros/luajit-src-rs and "patched" (hacked) this for myself.

I kind of rushed the "lua_resetthread" but that's all that it required so I figured maybe expand the luajit feature to something more customizable?

brandonros avatar Sep 11 '22 21:09 brandonros

You don't need to fork mlua if prefer to use your own luajit-src crate. You can override the dependency to use your fork via Cargo.toml:

[patch.crates-io]
luajit-src = { git = "https://github.com/brandonros/luajit-src-rs" }

khvzak avatar Sep 12 '22 08:09 khvzak

Would you be interested in supporting in luajit-src (and then pulling it into mlua behind a feature flag) a LuaJIT 2.0.5 branch?

brandonros avatar Sep 12 '22 14:09 brandonros

Are there any reasons to use LuaJIT 2.0.5 in vendored mode? I can understand when you have an external luajit library that you want to use, and mlua supports this case. The 2.0.5 branch looks as reached end of life. It even does not support properly 64bit targets and has issues on macos.

khvzak avatar Sep 13 '22 00:09 khvzak