Loading .github/workflows/ci.yml +4 −4 Original line number Diff line number Diff line Loading @@ -128,10 +128,10 @@ jobs: path: ~/.cargo/registry/cache key: registry-${{ runner.os }}-${{ steps.rust-version.outputs.version }}-${{ hashFiles('Cargo.lock') }} - run: cargo fetch - uses: actions/cache@v1 with: path: target key: target-${{ github.job }}-${{ steps.rust-version.outputs.version }}-${{ hashFiles('Cargo.lock') }} # - uses: actions/cache@v1 # with: # path: target # key: target-${{ github.job }}-${{ steps.rust-version.outputs.version }}-${{ hashFiles('Cargo.lock') }} - run: cargo run -p systest - run: cargo test -p openssl - run: cargo test -p openssl-errors Loading openssl-sys/build/main.rs +15 −2 Original line number Diff line number Diff line Loading @@ -19,7 +19,9 @@ mod find_normal; #[cfg(feature = "vendored")] mod find_vendored; #[derive(PartialEq)] enum Version { Openssl3xx, Openssl11x, Openssl10x, Libressl, Loading Loading @@ -94,7 +96,9 @@ fn main() { } None => match version { Version::Openssl10x if target.contains("windows") => vec!["ssleay32", "libeay32"], Version::Openssl11x if target.contains("windows-msvc") => vec!["libssl", "libcrypto"], Version::Openssl3xx | Version::Openssl11x if target.contains("windows-msvc") => { vec!["libssl", "libcrypto"] } _ => vec!["ssl", "crypto"], }, }; Loading @@ -104,6 +108,15 @@ fn main() { println!("cargo:rustc-link-lib={}={}", kind, lib); } // https://github.com/openssl/openssl/pull/15086 if version == Version::Openssl3xx && kind == "static" && env::var("CARGO_CFG_TARGET_OS").unwrap() == "linux" && env::var("CARGO_CFG_TARGET_POINTER_WIDTH").unwrap() == "32" { println!("cargo:rustc-link-lib=dylib=atomic"); } if kind == "static" && target.contains("windows") { println!("cargo:rustc-link-lib=dylib=gdi32"); println!("cargo:rustc-link-lib=dylib=user32"); Loading Loading @@ -253,7 +266,7 @@ See rust-openssl README for more information: if openssl_version >= 0x4_00_00_00_0 { version_error() } else if openssl_version >= 0x3_00_00_00_0 { Version::Openssl11x Version::Openssl3xx } else if openssl_version >= 0x1_01_01_00_0 { println!("cargo:version=111"); Version::Openssl11x Loading Loading
.github/workflows/ci.yml +4 −4 Original line number Diff line number Diff line Loading @@ -128,10 +128,10 @@ jobs: path: ~/.cargo/registry/cache key: registry-${{ runner.os }}-${{ steps.rust-version.outputs.version }}-${{ hashFiles('Cargo.lock') }} - run: cargo fetch - uses: actions/cache@v1 with: path: target key: target-${{ github.job }}-${{ steps.rust-version.outputs.version }}-${{ hashFiles('Cargo.lock') }} # - uses: actions/cache@v1 # with: # path: target # key: target-${{ github.job }}-${{ steps.rust-version.outputs.version }}-${{ hashFiles('Cargo.lock') }} - run: cargo run -p systest - run: cargo test -p openssl - run: cargo test -p openssl-errors Loading
openssl-sys/build/main.rs +15 −2 Original line number Diff line number Diff line Loading @@ -19,7 +19,9 @@ mod find_normal; #[cfg(feature = "vendored")] mod find_vendored; #[derive(PartialEq)] enum Version { Openssl3xx, Openssl11x, Openssl10x, Libressl, Loading Loading @@ -94,7 +96,9 @@ fn main() { } None => match version { Version::Openssl10x if target.contains("windows") => vec!["ssleay32", "libeay32"], Version::Openssl11x if target.contains("windows-msvc") => vec!["libssl", "libcrypto"], Version::Openssl3xx | Version::Openssl11x if target.contains("windows-msvc") => { vec!["libssl", "libcrypto"] } _ => vec!["ssl", "crypto"], }, }; Loading @@ -104,6 +108,15 @@ fn main() { println!("cargo:rustc-link-lib={}={}", kind, lib); } // https://github.com/openssl/openssl/pull/15086 if version == Version::Openssl3xx && kind == "static" && env::var("CARGO_CFG_TARGET_OS").unwrap() == "linux" && env::var("CARGO_CFG_TARGET_POINTER_WIDTH").unwrap() == "32" { println!("cargo:rustc-link-lib=dylib=atomic"); } if kind == "static" && target.contains("windows") { println!("cargo:rustc-link-lib=dylib=gdi32"); println!("cargo:rustc-link-lib=dylib=user32"); Loading Loading @@ -253,7 +266,7 @@ See rust-openssl README for more information: if openssl_version >= 0x4_00_00_00_0 { version_error() } else if openssl_version >= 0x3_00_00_00_0 { Version::Openssl11x Version::Openssl3xx } else if openssl_version >= 0x1_01_01_00_0 { println!("cargo:version=111"); Version::Openssl11x Loading