A small Bazel module that provides reusable VHDL dependency graph metadata via vhdl_library.
vhdl_library collects:
srcs (.vhd, .vhdl) — VHDL source filesdata — data files needed during compilation or simulationdeps — other vhdl_library targetslibrary — VHDL library name (defaults to "work")standard — VHDL standard version (optional; empty string means "unspecified")top_entity — the library's entry-point entity name (optional; empty string means "unspecified")and propagates a transitive VhdlInfo provider that downstream rules can consume.
Add to MODULE.bazel:
# See releases for available versions.
bazel_dep(name = "rules_vhdl", version = "{version}")
load("@rules_vhdl//vhdl:defs.bzl", "vhdl_library")
vhdl_library(
name = "utils",
srcs = ["utils_pkg.vhd"],
library = "my_utils",
)
vhdl_library(
name = "core",
srcs = ["core.vhd"],
deps = [":utils"],
)
vhdl_library(
name = "soc",
srcs = ["soc_top.vhdl"],
top_entity = "soc_top",
deps = [":core"],
)
VhdlInfo is exported from @rules_vhdl//vhdl:defs.bzl for custom rule authors.
Run all checks locally:
bazel test //...
Apache-2.0.
Provide foundational vhdl interfaces for Bazel rulesets (e.g., vhdl_library).
@hw-bzl/rules_vhdl