mirror of
https://github.com/JackA1ltman/NonGKI_Kernel_Build_2nd.git
synced 2026-08-19 15:03:40 +08:00
Page:
配置 YML 文件
Pages
Fork 项目
Home
en Automated Release
en Choosing a Toolchain
en Compiling on a Mobile Device
en Compiling the Kernel
en Compiling the Stock Vendor Kernel
en Configuring the YML File
en Embedding KernelSU and Patching SuSFS
en Fork the Repository
en Hiding Root Common Methods
en Introduction
en Kernel Build FAQ
en Packaging and Flashing
en Requirements
en Running and Downloading Artifacts
en Setting Up the Environment
en Variable Reference
内核编译答疑
利用移动设备编译内核
变量参考
基础需求
嵌入KernelSU和SuSFS修补
序章
打包与刷入
搭建基础环境
编译内核
编译器选择
编译设备厂商原始内核
自动发布
运行与产物
配置 YML 文件
隐藏Root常规方式
No results
Table of contents
This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
配置 YML 文件
利用 Action 构建内核 · 第二步
必须修改的基础字段
| 字段 | 说明 | 示例 |
|---|---|---|
DEVICE_NAME |
设备名称与型号 | oneplus_8 |
DEVICE_CODENAME |
设备代号 | polaris |
KERNEL_SOURCE |
内核源码 Git 链接 | |
KERNEL_BRANCH |
内核源码分支 | |
DEFCONFIG_NAME |
defconfig 完整名称(相对于 arch/arm64/configs/) |
vendor/mi845_defconfig |
执行系统配置
| 字段 | 可选值 |
|---|---|
runs-on |
ubuntu-latest / ubuntu-24.04 / ubuntu-22.04 |
container |
ubuntu:focal(20.04)/ archlinux / archlinux:latest |
自用时的最简配置清单
若只是为自己编译使用,通常只需修改以下变量:
EXTRA_CMDS(编译选项,如LD=ld.lld LLVM=1 LLVM_IAS=1)KERNEL_SOURCE和KERNEL_BRANCHCLANG_SOURCE和CLANG_BRANCHDEFCONFIG_NAMEKERNELSU_AUTO_GET和KERNELSU_AUTO_FORKSUSFS_ENABLE、SUSFS_FIXED、PATCHES_SOURCE、PATCHES_BRANCH、SUSFS_FOLDER_FIXED、SUSFS_PATCH_FIXED
额外编译步骤
若内核需要在编译前执行额外的 shell 代码,请添加至以下位置:
- name: 🪛 Extra Kernel Options
run: |
# 在此处添加你的 shell 代码
🌐 Language / 语言
📖 English
Local Build
- Setting Up the Environment
- Choosing a Toolchain
- Compiling the Kernel
- Compiling on a Mobile Device
- Compiling the Stock Vendor Kernel
- Embedding KernelSU & Patching SuSFS
- Packaging and Flashing
- Kernel Build FAQ
Build with Actions
- Fork the Repository
- Configuring the YML File
- Variable Reference
- Running and Downloading Artifacts
- Automated Release
Hide Root Trace
📖 中文
基础编译
利用 Action 构建内核
隐藏Root痕迹