Eyra

#OpenSource

Product information

Eyra is a Rust package designed to build programs entirely in Rust, eliminating the need for any external C libraries. It leverages several Rust-based tools, such as Origin for program and thread startup and shutdown, and c-gull for ABI-compatible libc function implementations. Eyra is compatible with Nightly Rust on Linux platforms, specifically x86-64, x86, aarch64, and riscv64 architectures.

To use Eyra, developers need to add it as a dependency in their Cargo.toml file and adjust their build.rs file to disable the host startup code, allowing Eyra to provide its own. This setup ensures that standard Rust commands like cargo build, cargo run, and cargo test operate seamlessly with Eyra on any -unknown-linux-gnu target.

Eyra addresses various issues in Rust, such as the set_var unsoundness and memory leaks in the environment-variable implementation. It supports whole-program LTO, which can result in smaller and faster binaries. Additionally, Eyra facilitates fully static linking, allowing executables to run without depending on dynamic libraries, although they still rely on a dynamic linker by default.

Despite its advantages, Eyra is not as mature or complete as major libc implementations and currently only supports Rust Nightly on Linux. It has limitations, such as lacking support for dynamic linking and being unable to run under Miri due to unrecognized syscalls from assembly code.

Eyra also offers optional logging features and compatibility with -Zbuild-std, making it suitable for producing very small statically-linked binaries using techniques from min-sized-rust. It shares similarities with Mustang, using the same underlying code but requiring users to add -nostartfiles to their link line.

The design philosophy behind Eyra emphasizes adhering to Rust's safety rules and separating the C compatibility layer from the core Rust implementation. This approach ensures that unsafe code is minimized and clearly delineated, providing a robust foundation for building Rust programs entirely in Rust.

Pricing

Pricing information is not available