-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathextract-files.sh
executable file
·31 lines (24 loc) · 1.02 KB
/
extract-files.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#!/bin/bash
#
# Copyright (C) 2019 The LineageOS Project
#
# SPDX-License-Identifier: Apache-2.0
#
# If we're being sourced by the common script that we called,
# stop right here. No need to go down the rabbit hole.
if [ "${BASH_SOURCE[0]}" != "${0}" ]; then
return
fi
set -e
# Required!
export DEVICE=perry
export DEVICE_COMMON=msm8937-common
export VENDOR=motorola
export DEVICE_BRINGUP_YEAR=2018
"./../../${VENDOR}/${DEVICE_COMMON}/extract-files.sh" "$@"
DEVICE_BLOB_ROOT="${LINEAGE_ROOT}/vendor/${VENDOR}/${DEVICE}/proprietary"
sed -i 's|/system/etc/camera|/vendor/etc/camera|g' "${DEVICE_BLOB_ROOT}/vendor/lib/libmmcamera2_sensor_modules.so"
patchelf --remove-needed libandroid.so "${DEVICE_BLOB_ROOT}/vendor/lib/libmmcamera_vstab_module.so"
patchelf --remove-needed libcamera_client.so "${DEVICE_BLOB_ROOT}/vendor/lib/libcamerabgprocservice.so"
sed -i 's|libgui|libwui|g' "${DEVICE_BLOB_ROOT}/vendor/lib/libmmcamera_ppeiscore.so"
patchelf --add-needed libppeiscore_shim.so "${DEVICE_BLOB_ROOT}/vendor/lib/libmmcamera_ppeiscore.so"