#![allow(non_upper_case_globals)]
#![allow(non_camel_case_types)]
#![allow(non_snake_case)]
#![allow(clippy::missing_safety_doc)]
use std::path::Path;
#[cfg(not(target_pointer_width = "32"))]
compile_error!("BYOND API only functions with 32-bit targets");
#[cfg(not(target_arch = "x86"))]
compile_error!("BYOND API only functions on x86 targets");
#[cfg(not(any(target_os = "linux", target_os = "windows")))]
compile_error!("BYOND API only supports Windows and Linux");
include!(concat!(env!("OUT_DIR"), "/bindings.rs"));
pub fn init(lib_path: &Path) -> ByondApi {
unsafe { ByondApi::new(lib_path).expect("Failed to load library") }
}
pub fn init_from_library<L>(library: L) -> ByondApi
where
L: Into<::libloading::Library>,
{
unsafe { ByondApi::from_library(library).expect("Failed to load library") }
}