cuest_ffi/lib.rs
1//! FFI bindings for cuEST (CUDA Electronic Structure Toolkit).
2//!
3//! This crate provides raw, unsafe FFI bindings to the cuEST C API,
4//! one-to-one with the C declarations. Prefer a safe wrapper (e.g.
5//! `cuest-cudarc`) over using this crate directly.
6//!
7//! The bindings are auto-generated from the cuEST public C headers; do not
8//! edit the generated files manually. See `scripts/generate_ffi.py`.
9//!
10//! cuEST itself is NVIDIA proprietary software and is not distributed with
11//! this crate; see the readme for how to obtain it and point this crate to it.
12//!
13//! # Loading Modes
14//!
15//! - **Dynamic loading** (default, `dynamic_loading` feature): `libcuest` is
16//! loaded at runtime via `libloading`. Set `CUEST_DYLOAD` to the library
17//! path, or let the crate search standard locations (see `ffi_dynamic` module
18//! documentation).
19//! - **Static linking** (`--no-default-features`): links `libcuest` at build
20//! time. Set `CUEST_LIB_DIR` if the library is in a nonstandard location.
21
22// Doxygen markers in the cuEST header comments (`[in]`, `[out]`, `<N>`, ...)
23// are not rustdoc links or HTML; keep the original comment text as-is.
24#![allow(rustdoc::broken_intra_doc_links)]
25#![allow(rustdoc::invalid_html_tags)]
26#![allow(non_snake_case)]
27
28#[cfg(not(feature = "dynamic_loading"))]
29pub mod ffi_static;
30#[cfg(not(feature = "dynamic_loading"))]
31pub use ffi_static as ffi;
32
33#[cfg(feature = "dynamic_loading")]
34pub mod ffi_dynamic;
35#[cfg(feature = "dynamic_loading")]
36pub use ffi_dynamic as ffi;
37
38pub mod status;