BurritoNg.Steps.Build.PackAndBuild (burrito_ng v1.0.0)

View Source

Summary

Functions

Verifies the Rust toolchain can build a wrapper for target, raising with instructions if not. Returns the linker environment to pass to Cargo.

Removes the build outputs of the wrapper crate (including the embedded payload) for the context's target, keeping its compiled dependencies cached.

The Cargo target directory used for wrapper builds. It is kept between builds so the wrapper's dependencies are only compiled once.

Path of the wrapper binary produced by execute/1 for the context's target.

Functions

check_toolchain!(target)

@spec check_toolchain!(BurritoNg.Builder.Target.t()) :: [{String.t(), String.t()}]

Verifies the Rust toolchain can build a wrapper for target, raising with instructions if not. Returns the linker environment to pass to Cargo.

Called before any phase runs, so a missing toolchain fails the build early.

clean(context)

@spec clean(BurritoNg.Builder.Context.t()) :: :ok

Removes the build outputs of the wrapper crate (including the embedded payload) for the context's target, keeping its compiled dependencies cached.

target_dir(context)

@spec target_dir(BurritoNg.Builder.Context.t()) :: String.t()

The Cargo target directory used for wrapper builds. It is kept between builds so the wrapper's dependencies are only compiled once.

wrapper_binary_path(context)

@spec wrapper_binary_path(BurritoNg.Builder.Context.t()) :: String.t()

Path of the wrapper binary produced by execute/1 for the context's target.