commit:     51e5cc9939d77ed4921dd8a05455c78c8cb7a0a4
Author:     orbea <orbea <AT> riseup <DOT> net>
AuthorDate: Fri Oct  7 14:52:28 2022 +0000
Commit:     Quentin Retornaz <gentoo <AT> retornaz <DOT> com>
CommitDate: Fri Oct  7 21:11:13 2022 +0000
URL:        https://gitweb.gentoo.org/repo/proj/libressl.git/commit/?id=51e5cc99

dev-lang/rust: Update patch for libressl 3.6.x

Signed-off-by: orbea <orbea <AT> riseup.net>
Signed-off-by: Quentin Retornaz <gentoo <AT> retornaz.com>

 dev-lang/rust/files/1.64.0-libressl.patch | 24 ++++++++++++++++++++++++
 dev-lang/rust/rust-1.64.0-r1.ebuild       |  9 ++++++++-
 2 files changed, 32 insertions(+), 1 deletion(-)

diff --git a/dev-lang/rust/files/1.64.0-libressl.patch 
b/dev-lang/rust/files/1.64.0-libressl.patch
new file mode 100644
index 0000000..88d4789
--- /dev/null
+++ b/dev-lang/rust/files/1.64.0-libressl.patch
@@ -0,0 +1,24 @@
+From: orbea <or...@riseup.net>
+Date: Sun, 3 Jul 2022 18:38:28 -0700
+Subject: [PATCH] Support LibreSSL 3.x.x
+
+--- a/vendor/libssh2-sys/build.rs
++++ b/vendor/libssh2-sys/build.rs
+@@ -121,6 +121,7 @@ fn main() {
+         cfg.define("HAVE_EVP_AES_128_CTR", None);
+         cfg.define("HAVE_POLL", None);
+         cfg.define("HAVE_GETTIMEOFDAY", None);
++        cfg.define("HAVE_OPAQUE_STRUCTS", None);
+ 
+         cfg.file("libssh2/src/openssl.c");
+ 
+--- a/vendor/openssl-sys/build/main.rs
++++ b/vendor/openssl-sys/build/main.rs
+@@ -254,6 +254,7 @@ See rust-openssl README for more information:
+             (3, 3, _) => ('3', '3', 'x'),
+             (3, 4, 0) => ('3', '4', '0'),
+             (3, 4, _) => ('3', '4', 'x'),
++            (3, _, _) => ('3', 'x', 'x'),
+             _ => version_error(),
+         };
+ 

diff --git a/dev-lang/rust/rust-1.64.0-r1.ebuild 
b/dev-lang/rust/rust-1.64.0-r1.ebuild
index b385ace..71eb093 100644
--- a/dev-lang/rust/rust-1.64.0-r1.ebuild
+++ b/dev-lang/rust/rust-1.64.0-r1.ebuild
@@ -162,7 +162,7 @@ RESTRICT="test"
 VERIFY_SIG_OPENPGP_KEY_PATH=${BROOT}/usr/share/openpgp-keys/rust.asc
 
 PATCHES=(
-       "${FILESDIR}"/1.62.0-libressl.patch
+       "${FILESDIR}"/1.64.0-libressl.patch
        "${FILESDIR}"/1.55.0-ignore-broken-and-non-applicable-tests.patch
        "${FILESDIR}"/1.62.1-musl-dynamic-linking.patch
        "${FILESDIR}"/${PV}-vendor-rustix-sparc-has-no-SIGSTKFLT.patch
@@ -292,6 +292,13 @@ src_prepare() {
                        --without=rust-docs --destdir="${rust_stage0_root}" 
--prefix=/ || die
        fi
 
+       # this libressl version check is terrible
+       sed -e 
's/d397af804c0b786978867528635fa9148cd2ad0e6abd591ace21b5bd3719c38d/896afea18b1072d4c715421ff2ed7e428b57aadec44d4680dcb991a6229a1edc/'
 \
+               -i vendor/openssl-sys/.cargo-checksum.json || die
+       # fix for libressl
+       sed -e 
's/7d5ca02f34cffe51db3568c500c9a8a70cef879871a0f466e3344142644acf12/e9eef35f1c18dd9844960d1d315e84ad99a05ab1247f0f54e3c2eab244988256/'
 \
+               -i vendor/libssh2-sys/.cargo-checksum.json || die
+
        default
 }
 

Reply via email to