forked from moto-msm89xx/android_device_motorola_cedric
-
Notifications
You must be signed in to change notification settings - Fork 0
/
extract-files.sh
executable file
·32 lines (25 loc) · 1.23 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
32
#!/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=cedric
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|/firmware/image|/vendor/f/image|' "${DEVICE_BLOB_ROOT}/vendor/bin/hw/[email protected]"
patchelf --remove-needed [email protected] "${DEVICE_BLOB_ROOT}/vendor/lib/[email protected]_vendor.so"
sed -i "s/libgui/libwui/" "${DEVICE_BLOB_ROOT}/vendor/lib/libmmcamera_ppeiscore.so"
patchelf --add-needed libppeiscore_shim.so "${DEVICE_BLOB_ROOT}/vendor/lib/libmmcamera_ppeiscore.so"
sed -i "s/system input/system uhid input/" "${DEVICE_BLOB_ROOT}/vendor/etc/init/[email protected]"
sed -i "s/class late_start/class hal/" "${DEVICE_BLOB_ROOT}/vendor/etc/init/[email protected]"