Skip to content

tucanos/libmeshb-sys

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

About

This is a bindgen wrapper of Loic Marechal's libMeshb.

Using

If libMeshb.7.so is not in the standard location you should define required environment variables in .cargo/config.toml (or define them in any other way):

[env]
LIBMESHB_INLCUDE_DIR="/path/to/libmeshb-install/include"
# or
LIBMESHB_DIR="/path/to/libmeshb-install"
# optionally
LIBMESHB_LIB_DIR="/path/to/lib"

Then

cargo add --git https://github.com/tucanos/libmeshb-sys.git

To have rpath propagated to your executables add the following code to you build.rs (see this bug report for details).

if let Ok(rpath) = std::env::var("DEP_MESHB.7_RPATH") {
    #[cfg(target_os = "macos")]
    println!("cargo:rustc-link-arg=-Wl,-rpath,{rpath}");
    #[cfg(target_os = "linux")]
    println!("cargo:rustc-link-arg=-Wl,-rpath,{rpath}");
}

Releases

No releases published

Packages

No packages published

Languages