You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

16 lines
433 B

  1. use std::env;
  2. macro_rules! set_rustc_env_var {
  3. ($name: expr, $value: expr) => {{
  4. println!("cargo:rustc-env={}={}", $name, $value);
  5. }};
  6. }
  7. fn main() {
  8. if let Ok(_) = env::var("DEP_OPENSSL_VERSION_NUMBER") {
  9. set_rustc_env_var!("ACMED_TLS_LIB_NAME", "OpenSSL");
  10. }
  11. if let Ok(_) = env::var("DEP_OPENSSL_LIBRESSL_VERSION_NUMBER") {
  12. set_rustc_env_var!("ACMED_TLS_LIB_NAME", "LibreSSL");
  13. }
  14. }