-
-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathupdate.sh
More file actions
57 lines (52 loc) · 1.25 KB
/
update.sh
File metadata and controls
57 lines (52 loc) · 1.25 KB
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
copy_library() {
DIR=`find /data/app -type d -name *$PKG*`
DES=$DIR/lib/$ARCH
if [ "$ARCH" ]; then
if echo "$ABI" | grep 64; then
if echo $DES | grep $PKG; then
mkdir -p $DES
for NAMES in $NAME; do
if [ -f /system/lib64/$NAMES ]; then
cp -f /system/lib64/$NAMES $DES
else
cp -f /system/apex/*/lib64/$NAMES $DES
cp -f /apex/*/lib64/$NAMES $DES
fi
done
chmod 0755 $DIR/*
chown -R 1000.1000 $DIR/lib
fi
else
if echo $DES | grep $PKG; then
mkdir -p $DES
for NAMES in $NAME; do
if [ -f /system/lib/$NAMES ]; then
cp -f /system/lib/$NAMES $DES
else
cp -f /system/apex/*/lib/$NAMES $DES
cp -f /apex/*/lib/$NAMES $DES
fi
done
chmod 0755 $DIR/*
chown -R 1000.1000 $DIR/lib
fi
fi
fi
}
ABI=`getprop ro.product.cpu.abi`
if [ "$ABI" == arm64-v8a ]; then
ARCH=arm64
elif [ "$ABI" == armeabi-v7a ] || [ "$ABI" == armeabi ]; then
ARCH=arm
elif [ "$ABI" == x86_64 ]; then
ARCH=x64
elif [ "$ABI" == x86 ]; then
ARCH=x86
elif [ "$ABI" == mips64 ]; then
ARCH=mips64
elif [ "$ABI" == mips ]; then
ARCH=mips
fi
PKG=com.sonyericsson.soundenhancement
NAME="libhscomp_jni.so libhscomp.so"
copy_library