# draupnir's **build thing** — the recipe, as a crate. CODE IS THE SOURCE.
#
# The 2026-08-27 law (dwarves/.nornir/build-thing-code-is-source-design.md): a
# build thing IS the Rust `impl BuildThing`, and `.nornir/build-variants.toml` is
# EMITTED from it — a description of the build, regenerated by
# `draupnir-build-thing emit`, never edited by hand and never read back as
# authority. Before this crate draupnir was one of the nine repos that declared
# only via a hand-written toml, which is a declaration nothing can check.
#
# The name is not a preference: dwarves' forge looks for a package named
# `<repo>-build-thing` under `crates/` or the repo root and refuses anything
# else BY NAME (`dwarves::build_thing::code::recipe_crate`).
[package]
name = "draupnir-build-thing"
version = "0.1.0"
edition = "2021"
rust-version = "1.85"
license = "MIT OR Apache-2.0"
repository = "https://git.gunnar.rs/mikronova/draupnir"
description = "draupnir's build thing: the boot/provisioning LIBRARY and the two backend shapes a consumer links, as typed Rust; .nornir/build-variants.toml is emitted from it."
# Path-deps edda's nornir-build-thing (the reader this repo needs is 0.1.12 and
# the constellation's recipes and their reader are edited in the same afternoon),
# so this crate is not published from here.
publish = false
[lib]
# `cdylib` is the wasm32 module the forge loads (a recipe crate that is not a
# cdylib is REFUSED BY NAME by dwarves `build_thing::code`); `rlib` is the native
# library the tests and the emit bin link. One source, no `cfg` fork.
crate-type = ["cdylib", "rlib"]
[[bin]]
# The emit door: `draupnir-build-thing emit` regenerates
# .nornir/build-variants.toml from `variants()`; `--list` prints the roster;
# `toml` prints the emission.
name = "draupnir-build-thing"
path = "src/main.rs"
[dependencies]
# The contract, the declaration types, the `plugin::BuildThing` trait and the ONE
# `code → toml` emitter (`nornir_build_thing::emit`, lane AG 2026-08-30).
# `default-features = false`: a declaration computes nothing heavy.
nornir-build-thing = { path = "../../../edda/crates/nornir-build-thing", version = "0.2.0", default-features = false }
anyhow = "1"
[dev-dependencies]
nornir-build-thing = { path = "../../../edda/crates/nornir-build-thing", version = "0.2.0", default-features = false }
[build-dependencies]
# The recipe's own content hash over its sources (`build.rs`): a receipt names
# the recipe by `krate:version:hash`.
sha2 = "0.11"