Shared RustlerPrecompiled options for both NIF crates.
The :targets list is the set scripts/build-precompiled.sh actually
produces. Windows is omitted on purpose — cargo-zigbuild cannot produce
x86_64-pc-windows-msvc, so Windows consumers source-build.
A missing checksum-*.exs source-builds in this repo's checkout so mix ci
is green before the first GitHub Release. The same missing file fails the
load for a Hex-installed package, where files: guarantees the checksum
ships. A checksum mismatch always fails; it never falls back to source.
Summary
Types
Whether checksum-Elixir.<Module>.exs exists on disk.
Hex tarball vs this repo (or a git/path dep).
Functions
Artifact filename rustler_precompiled downloads for a crate/target.
True when the NIF should compile from source instead of downloading.
Shipped OTP NIF versions. Must match RUSTLER_NIF_VERSION in the build script.
Keyword options for use RustlerPrecompiled.
Shipped Rust target triples. Must match scripts/build-precompiled.sh.
Types
Functions
Artifact filename rustler_precompiled downloads for a crate/target.
@spec force_build?( String.t() | nil, String.t() | nil, checksum_presence(), install_source() ) :: boolean()
True when the NIF should compile from source instead of downloading.
checksum :missing source-builds only for :checkout. A Hex install
with a missing checksum must not source-build — rustler_precompiled then
fails the load. A mismatch is never a reason to force-build.
@spec nif_versions() :: [String.t()]
Shipped OTP NIF versions. Must match RUSTLER_NIF_VERSION in the build script.
Keyword options for use RustlerPrecompiled.
Omits :force_build when the host should download, so the library's
application-env put_new still applies. Sets it to true for an
unsupported host, ONCHAIN_EVM_BUILD=1, or a missing checksum in this
checkout.
@spec targets() :: [String.t()]
Shipped Rust target triples. Must match scripts/build-precompiled.sh.