forked from SavedByLight/android_device_samsung_a12s
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathvendorsetup.sh
More file actions
68 lines (62 loc) · 2.11 KB
/
Copy pathvendorsetup.sh
File metadata and controls
68 lines (62 loc) · 2.11 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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
#
# This file is part of the OrangeFox Recovery Project
# Copyright (C) 2025 The OrangeFox Recovery Project
#
# OrangeFox is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# any later version.
#
# OrangeFox is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# This software is released under GPL version 3 or any later version.
# See <http://www.gnu.org/licenses/>.
#
# Please maintain this if you use this script or any part of it
#
#set -o xtrace
FDEVICE="a12s"
fox_get_target_device() {
local chkdev
if echo "$BASH_SOURCE" | grep -q "/$FDEVICE/"; then
FOX_BUILD_DEVICE="$FDEVICE"
elif set | grep BASH_ARGV | grep -w \"$FDEVICE\"; then
FOX_BUILD_DEVICE="$FDEVICE"
elif echo "${BASH_SOURCE[0]}" | grep -q "/$FDEVICE/"; then
FOX_BUILD_DEVICE="$FDEVICE"
elif echo "$0" | grep -q "$FDEVICE"; then
FOX_BUILD_DEVICE="$FDEVICE"
fi
}
if [ -z "$FOX_BUILD_DEVICE" ]; then
fox_get_target_device
fi
if [ "$1" = "$FDEVICE" -o "$FOX_BUILD_DEVICE" = "$FDEVICE" ]; then
export TW_DEFAULT_LANGUAGE="en"
export LC_ALL="C"
export ALLOW_MISSING_DEPENDENCIES=true
export FOX_VANILLA_BUILD=1
export FOX_NO_SAMSUNG_SPECIAL=1
export FOX_USE_BASH_SHELL=1
export FOX_ASH_IS_BASH=1
export FOX_USE_TAR_BINARY=1
export FOX_USE_XZ_UTILS=1
export FOX_USE_LZ4_BINARY=1
export FOX_USE_ZSTD_BINARY=1
export FOX_USE_DATE_BINARY=1
export FOX_RECOVERY_SYSTEM_PARTITION="/dev/block/mapper/system"
export FOX_RECOVERY_VENDOR_PARTITION="/dev/block/mapper/vendor"
export FOX_USE_SPECIFIC_MAGISK_ZIP=~/Magisk/Magisk-v30.6.zip
export FOX_DELETE_INITD_ADDON=1
export FOX_DELETE_AROMAFM=1
export FOX_USE_BUSYBOX_BINARY=1
else
if [ -z "$FOX_BUILD_DEVICE" -a -z "$BASH_SOURCE" ]; then
echo "I: This script requires bash. Not processing the $FDEVICE $(basename $0)"
fi
fi
#
chmod a+x device/samsung/a12s/mkbootimg