acodervic / zig-luajit

🦎 πŸŒ” Zig build of the LuaJIT repository created by @MikePall.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

🦎 πŸŒ” 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"));

About

🦎 πŸŒ” Zig build of the LuaJIT repository created by @MikePall.

License:MIT License


Languages

Language:Zig 100.0%