1 --- cargo-crates/openssl-sys-0.9.47/build/main.rs.orig 2019-05-09 01:41:17 UTC
2 +++ cargo-crates/openssl-sys-0.9.47/build/main.rs
3 @@ -183,28 +183,32 @@ See rust-openssl README for more informa
4 if let Some(libressl_version) = libressl_version {
5 println!("cargo:libressl_version_number={:x}", libressl_version);
7 + let major = (libressl_version >> 28) as u8;
8 let minor = (libressl_version >> 20) as u8;
9 let fix = (libressl_version >> 12) as u8;
10 - let (minor, fix) = match (minor, fix) {
11 - (5, 0) => ('5', '0'),
12 - (5, 1) => ('5', '1'),
13 - (5, 2) => ('5', '2'),
14 - (5, _) => ('5', 'x'),
15 - (6, 0) => ('6', '0'),
16 - (6, 1) => ('6', '1'),
17 - (6, 2) => ('6', '2'),
18 - (6, _) => ('6', 'x'),
19 - (7, _) => ('7', 'x'),
20 - (8, 0) => ('8', '0'),
21 - (8, 1) => ('8', '1'),
22 - (8, _) => ('8', 'x'),
23 - (9, 0) => ('9', '0'),
24 - (9, _) => ('9', 'x'),
25 + let (major, minor, fix) = match (major, minor, fix) {
26 + (2, 5, 0) => ('2', '5', '0'),
27 + (2, 5, 1) => ('2', '5', '1'),
28 + (2, 5, 2) => ('2', '5', '2'),
29 + (2, 5, _) => ('2', '5', 'x'),
30 + (2, 6, 0) => ('2', '6', '0'),
31 + (2, 6, 1) => ('2', '6', '1'),
32 + (2, 6, 2) => ('2', '6', '2'),
33 + (2, 6, _) => ('2', '6', 'x'),
34 + (2, 7, _) => ('2', '7', 'x'),
35 + (2, 8, 0) => ('2', '8', '0'),
36 + (2, 8, 1) => ('2', '8', '1'),
37 + (2, 8, _) => ('2', '8', 'x'),
38 + (2, 9, 0) => ('2', '9', '0'),
39 + (2, 9, _) => ('2', '9', 'x'),
40 + (3, 0, 0) => ('3', '0', '0'),
41 + (3, 0, 1) => ('3', '0', '1'),
42 + (3, 0, _) => ('3', '0', 'x'),
46 println!("cargo:libressl=true");
47 - println!("cargo:libressl_version=2{}{}", minor, fix);
48 + println!("cargo:libressl_version={}{}{}", major, minor, fix);
49 println!("cargo:version=101");
52 @@ -240,7 +244,7 @@ fn version_error() -> ! {
55 This crate is only compatible with OpenSSL 1.0.1 through 1.1.1, or LibreSSL 2.5
56 -through 2.9.x, but a different version of OpenSSL was found. The build is now aborting
57 +through 3.0.x, but a different version of OpenSSL was found. The build is now aborting
58 due to this version mismatch.