-
Notifications
You must be signed in to change notification settings - Fork 18
/
HOW-TO-BUILD
45 lines (34 loc) · 1.84 KB
/
HOW-TO-BUILD
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
This how-to is based to work on any Ubuntu or Ubuntu-based distros in 64-bit mode.
Download required tools:
1. Download tool for unpack/repack ramdisk "AIK-Linux" from https://forum.xda-developers.com/t/tool-android-image-kitchen-unpack-repack-kernel-ramdisk-win-android-linux-mac.2073775/
2. Downlaod toolchain "gcc-arm-8.3-2019.03-x86_64-aarch64-linux-gnu" from https://developer.arm.com/tools-and-software/open-source-software/developer-tools/gnu-toolchain/gnu-a/downloads/8-3-2019-03
3. Unpack a2n_kernel_g950x_9.x.zip to your HOME folder and don't change the structure of the files.
4. Put the unpacked toolchain and AIK-Linux to your HOME folder.
5. Grab the boot.img from "a2n_kernel_g950x_9.x" and copy it to the root of AIK-Linux
6. Open a new terminal emulator in the AIK-Linux folder and unpack ramdisk:
./unpackimg.sh --nosudo
7. Open a new terminal emulator in your HOME folder and download the source code:
git clone https://github.com/ace2nutzer/Samsung_dreamlte_Kernel.git
cd Samsung_dreamlte_Kernel
# apply wireguard patch
git apply wireguard.patch
8. Check the scripts:
clean.sh
edit.sh
build.sh
and adjust variables to your own.
### Steps to clean, edit and build the kernel ###
1. # cleanup source tree
./clean.sh
2. # edit kernel (enabled or disable drivers)
./edit.sh
3. # build kernel and create a flashable zip-file for e.g. TWRP
./build.sh
If the compilation will run without any errors, it'll give you a "a2n_kernel_g950x_9.x_user_build.zip" in the folder "a2n_kernel_g950x_9.x"
### HOW TO FIX BUILD ERRORS ###
e.g. if you get error: git: command not found or similar, then simply install the missing packages like this:
open a new terminal emulator and install missing "git" tool:
sudo apt-get install git
### NOTE ###
You are only allowed to download, edit, build and use the generated zip-file ONLY FOR YOUR OWN USAGE.
!! DO NOT RESTRIBUTE !!