jadarve / rules_lua

Bazel rules for the Lua programming language

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

rules_lua

Bazel rules for using the Lua language.

Configuration

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()

Available targets

Lua interpreter

It's possible to run the Lua interpreter directly:

bazel run @rules_lua//toolchains:lua 

Lua compiler

The compiler is avaialble as:

bazel run @rules_lua//toolchains:luac -- <compile options> 

Lua C library

Additionally, the C library is available as a dependency as @rules_lua//cc:lua_cc_library

Examples

See the examples folder to see how to use the rules.

About

Bazel rules for the Lua programming language

License:MIT License


Languages

Language:Starlark 100.0%