Bazel rules for using the Lua language.
Include the following configuration in your project's WORKSPACE
file.
load("@bazel_tools//tools/build_defs/repo:git.bzl", "git_repository")
git_repository(
name = "rules_lua",
remote = "https://github.com/jadarve/rules_lua.git",
tag = "v0.0.1"
)
load("@rules_lua//toolchains:repositories.bzl", "lua_repositories")
lua_repositories()
It's possible to run the Lua interpreter directly:
bazel run @rules_lua//toolchains:lua
The compiler is avaialble as:
bazel run @rules_lua//toolchains:luac -- <compile options>
Additionally, the C library is available as a dependency as @rules_lua//cc:lua_cc_library
See the examples folder to see how to use the rules.