Skip to content

Latest commit

 

History

History
51 lines (35 loc) · 1.61 KB

README.md

File metadata and controls

51 lines (35 loc) · 1.61 KB

🦎 🌔 zig luajit

CI License

Zig build of the LuaJIT repository created by Mike Pall.

🚀 Usage

  1. Add luajit as a dependency in your build.zig.zon.

    build.zig.zon example
    .{
        .name = "<name_of_your_package>",
        .version = "<version_of_your_package>",
        .dependencies = .{
            .luajit = .{
                .url = "https://github.com/tensorush/zig-luajit/archive/<git_tag_or_commit_hash>.tar.gz",
                .hash = "<package_hash>",
            },
        },
    }

    Set <package_hash> to 12200000000000000000000000000000000000000000000000000000000000000000, and Zig will provide the correct found value in an error message.

  2. Add luajit as a module in your build.zig.

    build.zig example
    const luajit = b.dependency("luajit", .{});
    exe.addModule("luajit", luajit.artifact("lib"));