Binary distribution
PowerIO.jl wraps the Rust powerio-capi library. On a supported platform it arrives as a prebuilt binary, so you do not compile anything.
Pipeline
- A version tag on eigenergy/powerio triggers its
release-binariesworkflow, which buildslibpowerio_capi.<triplet>.tar.gzwith thearrow,matrix,gridfm,dist, andprobfeatures for Linux glibc (x86_64,aarch64), macOS (x86_64,arm64), and Windows (x86_64), and attaches the five tarballs to the GitHub release. Each tarball holds the library underlib/(bin/on Windows), the C header underinclude/, and the licenses. - A reviewed
.github/powerio-release.tomlnames the exact tag and binds it to the final Julia source digest. "Update artifacts" downloads the five tarballs, computes each one's SHA-256 and unpacked git tree hash, and asksgen/update_artifacts.jlto buildArtifacts.toml. Before writing, the generator loads the host library and checks its ABI number (7), its version string against the tag, the core entry points the binding calls, and that it parses the GridFM fixture. If any of those checks fail, the update is parked andArtifacts.tomlis left untouched. The workflow tests the exact result, commits onlyArtifacts.toml, pushes only whenmainhas not moved, and dispatches registration for that exact SHA. See CONTRIBUTING.md for the state machine and recovery commands. Artifacts.tomlis lazy, soPkg.adddownloads nothing; the tarball for your platform is fetched on the first call that needs the library.
A PowerIO_jll built from gen/build_tarballs.jl (the BinaryBuilder recipe) is the planned long term distribution; current releases use the artifact pipeline above.
Resolution order
The library resolves in this order:
set_library!(path)or thePOWERIO_CAPIenvironment variable,- the saved Preferences.jl
libraryoverride, - a sibling
poweriocheckout'starget/{release,debug}build, only when this package is itself a git checkout, - the
powerio_capiartifact, - a plain
libpowerio_capion the loader path.
On an unsupported platform the artifact lookup fails, and the other entries let you keep working from a local build.
using PowerIO
set_library!("/path/to/libpowerio_capi.dylib"; persist=true)
clear_library!(persist=true)PowerIO.set_library! — Function
set_library!(path; persist=false)Point PowerIO at a locally built libpowerio_capi (cargo build -p powerio-capi --release in the powerio Rust tree writes target/release/libpowerio_capi.{dylib,so}). An in-session override wins over POWERIO_CAPI, the saved Preferences.jl override, and the bundled artifact. Pass persist=true to save the path in the active environment's LocalPreferences.toml.
PowerIO.clear_library! — Function
clear_library!(; persist=false)Clear the in-session library override. Pass persist=true to also clear the saved Preferences.jl library override. POWERIO_CAPI, when set, still wins on this session's next call.
PowerIO.abi_version — Function
abi_version() -> UInt32The ABI version the resolved C library was built with (see pio_abi_version). Compared against PIO_ABI_VERSION, the version this binding targets.
PowerIO.library_version — Function
library_version() -> StringThe powerio crate version string the resolved library reports, such as "0.11.0". Informational; abi_version is the compatibility check.
PowerIO.library_available — Function
library_available() -> BoolTrue if the C ABI library resolves and is ABI compatible with this binding (see abi_version).