| Crates.io | rldd-rex |
| lib.rs | rldd-rex |
| version | 1.0.3 |
| created_at | 2025-11-03 01:05:36.578953+00 |
| updated_at | 2025-12-14 18:35:03.904131+00 |
| description | Minimalistic recursive ELF dependency resolver for Linux, BSDs, and Solaris. |
| homepage | |
| repository | https://github.com/LinuxDicasPro/rldd-rex |
| max_upload_size | |
| id | 1913757 |
| size | 945,332 |
rldd-rex is a minimal Rust library designed to recursively inspect ELF binaries
and their shared library dependencies. It was specifically created for integration with
the Rex - Static Rust Executable, prioritizing
portability, robustness, and security over feature complexity.
This library is intentionally minimal; most features are focused on safe,
reliable ELF parsing and dependency resolution.
Elf32 / Elf64.Static, Dynamic, PIE, Invalid.LD_LIBRARY_PATH via the enable_ld_library_path feature.⚠️ Note: This project emphasizes minimalism and robust integration with the Rex project. It avoids extra features, focusing only on compatibility, portability, dependency resolution, binary architecture and type detection, error handling, and security.
Add rldd-rex to your Cargo.toml:
[dependencies]
rldd-rex = "1.0"
To enable LD_LIBRARY_PATH support:
rldd-rex = { version = "1.0", features = ["enable_ld_library_path"] }
use rldd_rex::*;
fn main() -> std::io::Result<()> {
let path = "/usr/bin/ocenaudio";
let deps_info = rldd_rex(path)?;
println!("ELF Type: {:?}", deps_info.elf_type);
println!("Architecture: {:?}", deps_info.arch);
println!("Dependencies:");
for (i, (lib, path_or_status)) in deps_info.deps.iter().enumerate() {
let num = i + 1;
if path_or_status == "not found" {
println!("{num}. {} => \x1b[1;31mnot found\x1b[0m", lib);
} else {
println!("{num}. {} => {}", lib, path_or_status);
}
}
Ok(())
}
rldd-rex is ideal for projects that require:
It is not intended as a full-featured replacement for ldd or other ELF tools.
It is focused on robustness, minimalism, and security.
enable_ld_library_path: Reads and respects the LD_LIBRARY_PATH environment variable,
adding extra search directories for ELF libraries.Only ELF binaries are supported.
This project is licensed under the MIT License. See the LICENSE file for details.
rldd-rex is a minimalistic library by design. Its main purpose is to provide a
robust, portable, and secure ELF dependency resolver, specifically built to integrate
seamlessly with the Rex - Static Rust Executable.
Because of this tight integration and focus on minimalism,
adding new features outside the core functionality is strongly discouraged.
The library intentionally avoids extra features to maintain:
Contributions are welcome if they follow these principles, such as:
Pull requests that introduce new features unrelated to dependency resolution or ELF parsing will likely be declined, to preserve the library’s minimalistic and reliable design.