forked from rsuplaygrnd/crave_aosp_script
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild_miku.sh
More file actions
44 lines (36 loc) · 1.08 KB
/
Copy pathbuild_miku.sh
File metadata and controls
44 lines (36 loc) · 1.08 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
# cleanup
remove_lists=(
.repo/local_manifests
prebuilts/clang/host/linux-x86
device/qcom/sepolicy
device/qcom/sepolicy-legacy-um
device/qcom/sepolicy_vndr/legacy-um
device/asus/sdm660-common
device/asus/X01BD
kernel/asus/sdm660
out/target/product/X01BD
external/chromium-webview
)
rm -rf "${remove_lists[@]}"
# init repo
repo init --depth=1 --no-repo-verify --git-lfs -u https://github.com/rsuntk/manifesto.git -b Blooming -g default,-mips,-darwin,-notdefault
# clone local manifests
git clone https://github.com/rsuplaygrnd/local_manifest --depth 1 -b X01BD-miku .repo/local_manifests
# repo sync
[ -f /usr/bin/resync ] && /usr/bin/resync || /opt/crave/resync.sh
# setup KernelSU
if [ -d kernel/asus/sdm660 ]; then
cd kernel/asus/sdm660
curl -LSs "https://raw.githubusercontent.com/rsuntk/KernelSU/main/kernel/setup.sh" | bash -s main
cd ../../..
fi
# Set up build environment
export BUILD_USERNAME=rsuntk
export BUILD_HOSTNAME=nobody
export TZ="Asia/Jakarta"
source build/envsetup.sh
# Build the ROM
lunch miku_X01BD-bp2a-user
make installclean
make diva
[ -d out ] && ls out/target/product/X01BD