diff options
| author | Steven Fackler <[email protected]> | 2014-12-05 10:50:40 -0500 |
|---|---|---|
| committer | Steven Fackler <[email protected]> | 2014-12-05 10:50:40 -0500 |
| commit | b8a41f79a1a78791dddd453db0aab5f0957152fc (patch) | |
| tree | 72196c357f85b47a7032bcfbe1d27d95fa703061 | |
| parent | Merge pull request #109 from Manishearth/android (diff) | |
| parent | Directly substitute $OPENSSL_PATH (diff) | |
| download | rust-openssl-b8a41f79a1a78791dddd453db0aab5f0957152fc.tar.xz rust-openssl-b8a41f79a1a78791dddd453db0aab5f0957152fc.zip | |
Merge pull request #110 from Manishearth/patch-1
Directly substitute $OPENSSL_PATH
| -rw-r--r-- | openssl-sys/src/build.rs | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/openssl-sys/src/build.rs b/openssl-sys/src/build.rs index df284c0f..707a8e65 100644 --- a/openssl-sys/src/build.rs +++ b/openssl-sys/src/build.rs @@ -18,13 +18,11 @@ fn main() { flags.push_str(" -l gdi32 -l wsock32"); } - // Android doesn't have libcrypto/libssl, - // the toplevel Rust program should compile it themselves if target.find_str("android").is_some() { - os::getenv("OPENSSL_PATH").expect("Android does not provide openssl libraries, please \ - build them yourselves (instructions in the README) \ - and provide their location through $OPENSSL_PATH."); - flags.push_str(" -L ${OPENSSL_PATH}"); + let path = os::getenv("OPENSSL_PATH").expect("Android does not provide openssl libraries, please \ + build them yourselves (instructions in the README) \ + and provide their location through $OPENSSL_PATH."); + flags.push_str(format!(" -L {}", path).as_slice()); } println!("cargo:rustc-flags={}", flags); |