Created
December 24, 2019 09:58
-
-
Save a1ien/d94caafa888a8707015558a696162783 to your computer and use it in GitHub Desktop.
libusb use libudev pkgconfig
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
match pkg_config::probe_library("libudev") { | |
Ok(lib) => { | |
for lib_dir in &lib.link_paths { | |
println!("cargo:lib={}", lib_dir.to_str().unwrap()); | |
} | |
for include_dir in &lib.include_paths { | |
println!("cargo:include={}", include_dir.to_str().unwrap()); | |
} | |
base_config.define("USE_UDEV", Some("1")); | |
base_config.define("HAVE_LIBUDEV", Some("1")); | |
base_config.define("HAVE_LIBUDEV_H", Some("1")); | |
} | |
_=>{} | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment