diff options
| author | Adrian Bunk <bunk@stusta.de> | 2019-03-07 09:26:58 +0200 |
|---|---|---|
| committer | Khem Raj <raj.khem@gmail.com> | 2019-03-07 09:33:45 -0800 |
| commit | 335bb5297def5804fee657eaa3c386eba984be91 (patch) | |
| tree | b58deacb9d3b2189d06a16faede24684ad5164e1 | |
| parent | d9de836c5f53af232dc1bc120999b8a8c555491d (diff) | |
| download | meta-openembedded-335bb5297def5804fee657eaa3c386eba984be91.tar.gz | |
android-tools: Add patch from Debian to build with OpenSSL 1.1
Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
| -rw-r--r-- | meta-oe/recipes-devtools/android-tools/android-tools/core/adb_libssl_11.diff | 39 | ||||
| -rw-r--r-- | meta-oe/recipes-devtools/android-tools/android-tools_5.1.1.r37.bb | 3 |
2 files changed, 41 insertions, 1 deletions
diff --git a/meta-oe/recipes-devtools/android-tools/android-tools/core/adb_libssl_11.diff b/meta-oe/recipes-devtools/android-tools/android-tools/core/adb_libssl_11.diff new file mode 100644 index 0000000000..3ead649b1d --- /dev/null +++ b/meta-oe/recipes-devtools/android-tools/android-tools/core/adb_libssl_11.diff | |||
| @@ -0,0 +1,39 @@ | |||
| 1 | Description: adb: Make compatible with openssl 1.1 | ||
| 2 | OpenSSL version 1.1 brought some API changes which broke the build here, | ||
| 3 | fix that by accessing rsa->n (and e) directly, using RSA_get0_key instead. | ||
| 4 | Author: Chirayu Desai <chirayudesai1@gmail.com | ||
| 5 | Last-Update: 2016-11-10 | ||
| 6 | --- | ||
| 7 | This patch header follows DEP-3: http://dep.debian.net/deps/dep3/ | ||
| 8 | --- | ||
| 9 | system/core/adb/adb_auth_host.c | 5 +++-- | ||
| 10 | 1 file changed, 3 insertions(+), 2 deletions(-) | ||
| 11 | |||
| 12 | --- a/adb/adb_auth_host.c | ||
| 13 | +++ b/adb/adb_auth_host.c | ||
| 14 | @@ -75,6 +75,7 @@ static int RSA_to_RSAPublicKey(RSA *rsa, | ||
| 15 | BIGNUM* rem = BN_new(); | ||
| 16 | BIGNUM* n = BN_new(); | ||
| 17 | BIGNUM* n0inv = BN_new(); | ||
| 18 | + BIGNUM* e = BN_new(); | ||
| 19 | |||
| 20 | if (RSA_size(rsa) != RSANUMBYTES) { | ||
| 21 | ret = 0; | ||
| 22 | @@ -82,7 +83,7 @@ static int RSA_to_RSAPublicKey(RSA *rsa, | ||
| 23 | } | ||
| 24 | |||
| 25 | BN_set_bit(r32, 32); | ||
| 26 | - BN_copy(n, rsa->n); | ||
| 27 | + RSA_get0_key(rsa, &n, &e, NULL); | ||
| 28 | BN_set_bit(r, RSANUMWORDS * 32); | ||
| 29 | BN_mod_sqr(rr, r, n, ctx); | ||
| 30 | BN_div(NULL, rem, n, r32, ctx); | ||
| 31 | @@ -96,7 +97,7 @@ static int RSA_to_RSAPublicKey(RSA *rsa, | ||
| 32 | BN_div(n, rem, n, r32, ctx); | ||
| 33 | pkey->n[i] = BN_get_word(rem); | ||
| 34 | } | ||
| 35 | - pkey->exponent = BN_get_word(rsa->e); | ||
| 36 | + pkey->exponent = BN_get_word(e); | ||
| 37 | |||
| 38 | out: | ||
| 39 | BN_free(n0inv); | ||
diff --git a/meta-oe/recipes-devtools/android-tools/android-tools_5.1.1.r37.bb b/meta-oe/recipes-devtools/android-tools/android-tools_5.1.1.r37.bb index d49e53714d..e09cd829d7 100644 --- a/meta-oe/recipes-devtools/android-tools/android-tools_5.1.1.r37.bb +++ b/meta-oe/recipes-devtools/android-tools/android-tools_5.1.1.r37.bb | |||
| @@ -8,7 +8,7 @@ LIC_FILES_CHKSUM = " \ | |||
| 8 | file://${COMMON_LICENSE_DIR}/BSD-3-Clause;md5=550794465ba0ec5312d6919e203a55f9 \ | 8 | file://${COMMON_LICENSE_DIR}/BSD-3-Clause;md5=550794465ba0ec5312d6919e203a55f9 \ |
| 9 | " | 9 | " |
| 10 | DEPENDS = "libbsd libpcre zlib libcap" | 10 | DEPENDS = "libbsd libpcre zlib libcap" |
| 11 | DEPENDS_append_class-target = " openssl10" | 11 | DEPENDS_append_class-target = " openssl" |
| 12 | 12 | ||
| 13 | ANDROID_MIRROR = "android.googlesource.com" | 13 | ANDROID_MIRROR = "android.googlesource.com" |
| 14 | 14 | ||
| @@ -37,6 +37,7 @@ SRC_URI = " \ | |||
| 37 | file://core/0010-Use-linux-capability.h-on-linux-systems-too.patch;patchdir=system/core \ | 37 | file://core/0010-Use-linux-capability.h-on-linux-systems-too.patch;patchdir=system/core \ |
| 38 | file://core/0011-Remove-bionic-specific-calls.patch;patchdir=system/core \ | 38 | file://core/0011-Remove-bionic-specific-calls.patch;patchdir=system/core \ |
| 39 | file://core/0012-Fix-implicit-declaration-of-stlcat-strlcopy-function.patch;patchdir=system/core \ | 39 | file://core/0012-Fix-implicit-declaration-of-stlcat-strlcopy-function.patch;patchdir=system/core \ |
| 40 | file://core/adb_libssl_11.diff;patchdir=system/core \ | ||
| 40 | file://extras/0001-ext4_utils-remove-selinux-extensions.patch;patchdir=system/extras \ | 41 | file://extras/0001-ext4_utils-remove-selinux-extensions.patch;patchdir=system/extras \ |
| 41 | file://extras/0002-ext4_utils-add-o-argument-to-preserve-ownership.patch;patchdir=system/extras \ | 42 | file://extras/0002-ext4_utils-add-o-argument-to-preserve-ownership.patch;patchdir=system/extras \ |
| 42 | file://libselinux/0001-Remove-bionic-specific-calls.patch;patchdir=external/libselinux \ | 43 | file://libselinux/0001-Remove-bionic-specific-calls.patch;patchdir=external/libselinux \ |
