-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild-ksu.sh
More file actions
42 lines (37 loc) · 1.14 KB
/
Copy pathbuild-ksu.sh
File metadata and controls
42 lines (37 loc) · 1.14 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
#!/bin/bash
# Copyright (C) 2024 psionicprjkt
compile_kernel() {
# compile_kernel
export ARCH=arm64
make O=out ARCH=arm64 salaa_defconfig
# Generate profile data during the first compilation
PATH="${PWD}/clang/bin:${PWD}/arm64:${PWD}/arm32:${PATH}" \
make -j"$(nproc --all)" O=out \
LLVM=1 \
LLVM_IAS=1 \
ARCH=arm64 \
CC="clang" \
LD=ld.lld \
STRIP=llvm-strip \
AS=llvm-as \
AR=llvm-ar \
NM=llvm-nm \
OBJCOPY=llvm-objcopy \
OBJDUMP=llvm-objdump \
CLANG_TRIPLE=aarch64-linux-gnu- \
CROSS_COMPILE="${PWD}/arm64/aarch64-linux-android-" \
CROSS_COMPILE_ARM32="${PWD}/arm32/arm-linux-androideabi-" \
CONFIG_NO_ERROR_ON_MISMATCH=y \
CFLAGS="-Wno-pragma-messages"
}
setup_kernel_release() {
# setup_kernel_release
v=$(cat version)
d=$(date "+%d%m%Y")
z="psionic-kernel-salaa-$d-$v-ksu.zip"
wget --quiet https://psionicprjkt.my.id/assets/files/AK3-salaa.zip && unzip AK3-salaa
cp out/arch/arm64/boot/Image.gz-dtb AnyKernel && cd AnyKernel
zip -r9 "$z" *
}
compile_kernel
setup_kernel_release