From 05effbbfc2fc6223aafacf8a3cb2b2d970b6bb66 Mon Sep 17 00:00:00 2001 From: Giovanni Biscuolo Date: Thu, 12 Aug 2021 18:09:02 +0200 Subject: gnu: adb: Make compatible with OpenSSL 1.1. OpenSSL version 1.1 brought some API changes which broke the build here, fix that by accessing rsa->n (and e) directly, using RSA_get0_key instead. * gnu/packages/patches/adb-libssl_11-compatibility.patch: New file * gnu/local.mk (dist_patch_DATA): Add it. * gnu/packages/android.scm (android-platform-system-core)[origin]: Use it. (adb)[inputs]: Replace openssl-1.0 with openssl. --- .../patches/adb-libssl_11-compatibility.patch | 35 ++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 gnu/packages/patches/adb-libssl_11-compatibility.patch (limited to 'gnu/packages/patches') diff --git a/gnu/packages/patches/adb-libssl_11-compatibility.patch b/gnu/packages/patches/adb-libssl_11-compatibility.patch new file mode 100644 index 0000000000..9affe58b5d --- /dev/null +++ b/gnu/packages/patches/adb-libssl_11-compatibility.patch @@ -0,0 +1,35 @@ +This patch is taken from Debian +URL: https://sources.debian.org/data/main/a/android-platform-system-core/1%3A7.0.0%2Br33-1/debian/patches/adb_libssl_11.diff +Description: adb: Make compatible with openssl 1.1 + OpenSSL version 1.1 brought some API changes which broke the build here, + fix that by accessing rsa->n (and e) directly, using RSA_get0_key instead. +Author: Chirayu Desai n); ++ RSA_get0_key(rsa, &n, &e, NULL); + BN_set_bit(r, RSANUMWORDS * 32); + BN_mod_sqr(rr, r, n, ctx); + BN_div(NULL, rem, n, r32, ctx); +@@ -92,7 +93,7 @@ + BN_div(n, rem, n, r32, ctx); + pkey->n[i] = BN_get_word(rem); + } +- pkey->exponent = BN_get_word(rsa->e); ++ pkey->exponent = BN_get_word(e); + + out: + BN_free(n0inv); -- cgit v1.2.3