sm7125-common: Add shim for updated libcrypto

Change-Id: I3bf41472129090c68b81afd749e9e474b88954a8

# Conflicts:
#	common.mk
urubino
Jenna-they-them 2 months ago
parent d1f0635f3c
commit 47a996fd83
  1. 6
      common.mk
  2. 2
      extract-files.sh
  3. 2
      proprietary-files.txt
  4. 22
      shims/libcrypto/Android.bp
  5. 37
      shims/libcrypto/crypto.c
  6. 14
      vndk/Android.bp
  7. 1
      vndk/libssl-v33.so

@ -216,9 +216,13 @@ PRODUCT_COPY_FILES += \
# Keymaster
PRODUCT_PACKAGES += \
android.hardware.keymaster@4.0-service.samsung \
libcrypto-v33 \
libkeymaster4_1support.vendor
PRODUCT_PACKAGES += \
libcrypto-v33 \
libshim_crypto:64 \
libssl-v33
# LiveDisplay
PRODUCT_PACKAGES += \
vendor.lineage.livedisplay@2.0-service.samsung-qcom.sm7125

@ -73,6 +73,8 @@ function blob_fixup() {
;;
vendor/lib*/libskeymaster4device.so)
"${PATCHELF}" --replace-needed libcrypto.so libcrypto-v33.so "${2}"
"${PATCHELF}" --add-needed libssl-v33.so "${2}"
"${PATCHELF}" --add-needed libshim_crypto.so "${2}"
;;
vendor/lib*/hw/gatekeeper.mdfpp.so)
"${PATCHELF}" --replace-needed libcrypto.so libcrypto-v33.so "${2}"

@ -737,7 +737,7 @@ vendor/firmware/ipa_fws.mdt
# Keymaster
vendor/lib64/libkeymaster_helper.so
-vendor/lib64/libskeymaster4device.so|e4dcee6306be79bb3ca271466afeabd1b0b966d5
-vendor/lib64/libskeymaster4device.so|bc98d0220e22831a46c9229b0da218876627c3c3
# Machine learning
vendor/lib64/libreffeature.so

@ -0,0 +1,22 @@
//
// Copyright (C) 2023-2024 The LineageOS Project
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
cc_library_shared {
name: "libshim_crypto",
srcs: ["crypto.c"],
compile_multilib: "64",
shared_libs: ["libcrypto-v33"],
vendor: true,
}

@ -0,0 +1,37 @@
/*
* Copyright (C) 2024 The LineageOS Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include <stddef.h>
extern void *sk_new_null(void);
void *OPENSSL_sk_new_null(void) {
return sk_new_null();
}
extern size_t sk_num(void *sk);
size_t OPENSSL_sk_num(void *sk) {
return sk_num(sk);
}
extern size_t sk_push(void *sk, void *p);
size_t OPENSSL_sk_push(void *sk, void *p) {
return sk_push(sk, p);
}
extern void *sk_value(const void *sk, size_t i);
void* OPENSSL_sk_value(const void *sk, size_t i) {
return sk_value(sk, i);
}

@ -1,5 +1,5 @@
//
// Copyright (C) 2023 The LineageOS Project
// Copyright (C) 2023-2024 The LineageOS Project
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@ -25,3 +25,15 @@ cc_prebuilt_library_shared {
check_elf_files: false,
vendor: true,
}
cc_prebuilt_library_shared {
name: "libssl-v33",
target: {
android_arm64: {
srcs: ["libssl-v33.so"],
},
},
compile_multilib: "64",
check_elf_files: false,
vendor: true,
}

@ -0,0 +1 @@
../../../../prebuilts/vndk/v33/arm64/arch-arm64-armv8-a/shared/vndk-core/libssl.so
Loading…
Cancel
Save