sm7125-common: Use libcrypto from VNDK33 for keymaster and gatekeeper

* Google broke asn1 structs in 9211b80f1e
  by changing types from long to int making the struct used by the blob mismatch new libcrypto

Change-Id: I8b110e9841bd9b50ea482aa98c0963567a69f6fc
urubino-microg
Tim Zimmermann 1 year ago committed by Ruchit
parent 71e04fc98e
commit 77e9b72189
  1. 1
      common.mk
  2. 6
      extract-files.sh
  3. 27
      vndk/Android.bp
  4. 1
      vndk/libcrypto-v33.so

@ -225,6 +225,7 @@ PRODUCT_COPY_FILES += \
# Keymaster
PRODUCT_PACKAGES += \
android.hardware.keymaster@4.0-service.samsung \
libcrypto-v33 \
libkeymaster4_1support.vendor
# Media

@ -70,6 +70,12 @@ function blob_fixup() {
# Replace libutils with vndk30 libutils
"${PATCHELF}" --replace-needed libutils.so libutils-v30.so "${2}"
;;
vendor/lib*/libskeymaster4device.so)
"${PATCHELF}" --replace-needed libcrypto.so libcrypto-v33.so "${2}"
;;
vendor/lib*/hw/gatekeeper.mdfpp.so)
"${PATCHELF}" --replace-needed libcrypto.so libcrypto-v33.so "${2}"
;;
esac
}

@ -0,0 +1,27 @@
//
// Copyright (C) 2023 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_prebuilt_library_shared {
name: "libcrypto-v33",
target: {
android_arm64: {
srcs: ["libcrypto-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/libcrypto.so
Loading…
Cancel
Save