Loading README.md +2 −0 Original line number Diff line number Diff line Loading @@ -133,6 +133,8 @@ The build script can be configured via environment variables: (if specified). * `OPENSSL_STATIC` - If specified, OpenSSL libraries will be statically rather than dynamically linked. * `OPENSSL_LIBS` - If specified, the names of the OpenSSL libraries that will be linked, e.g. `ssl:crypto`. If `OPENSSL_DIR` is specified, then the build script will skip the pkg-config step. Loading openssl-sys/build.rs +13 −6 Original line number Diff line number Diff line Loading @@ -65,16 +65,23 @@ fn main() { let version = validate_headers(&[include_dir.clone().into()]); let libs = match version { let libs_env = env::var("OPENSSL_LIBS").ok(); let libs = match libs_env { Some(ref v) => v.split(":").collect(), None => { match version { Version::Openssl101 | Version::Openssl102 if target.contains("windows") => { ["ssleay32", "libeay32"] vec!["ssleay32", "libeay32"] } Version::Openssl110 if target.contains("windows") => vec!["libssl", "libcrypto"], _ => vec!["ssl", "crypto"], } } Version::Openssl110 if target.contains("windows") => ["libssl", "libcrypto"], _ => ["ssl", "crypto"], }; let kind = determine_mode(Path::new(&lib_dir), &libs); for lib in libs.iter() { for lib in libs.into_iter() { println!("cargo:rustc-link-lib={}={}", kind, lib); } } Loading Loading
README.md +2 −0 Original line number Diff line number Diff line Loading @@ -133,6 +133,8 @@ The build script can be configured via environment variables: (if specified). * `OPENSSL_STATIC` - If specified, OpenSSL libraries will be statically rather than dynamically linked. * `OPENSSL_LIBS` - If specified, the names of the OpenSSL libraries that will be linked, e.g. `ssl:crypto`. If `OPENSSL_DIR` is specified, then the build script will skip the pkg-config step. Loading
openssl-sys/build.rs +13 −6 Original line number Diff line number Diff line Loading @@ -65,16 +65,23 @@ fn main() { let version = validate_headers(&[include_dir.clone().into()]); let libs = match version { let libs_env = env::var("OPENSSL_LIBS").ok(); let libs = match libs_env { Some(ref v) => v.split(":").collect(), None => { match version { Version::Openssl101 | Version::Openssl102 if target.contains("windows") => { ["ssleay32", "libeay32"] vec!["ssleay32", "libeay32"] } Version::Openssl110 if target.contains("windows") => vec!["libssl", "libcrypto"], _ => vec!["ssl", "crypto"], } } Version::Openssl110 if target.contains("windows") => ["libssl", "libcrypto"], _ => ["ssl", "crypto"], }; let kind = determine_mode(Path::new(&lib_dir), &libs); for lib in libs.iter() { for lib in libs.into_iter() { println!("cargo:rustc-link-lib={}={}", kind, lib); } } Loading