Builds Android kernel from the kernel repository.
| Input | Description |
|---|---|
arch | Specify what Architecture target to use, currently only supports arm64 |
compiler | Specify which toochain to use |
defconfig | Specify what defconfig command used to generate .config file |
image | Specify what is the final build file, usually it's Image.gz-dtb or Image-dtb |
| Variable | Description |
|---|---|
NAME | Specify the name of the release file, defaults to the name of the repository |
KERNEL_PATH | Specify the path of the kernel source, defaults to . |
ZIPPER_PATH | Specify the path of the zip template, defaults to zipper |
| Output | Description |
|---|---|
elapsed_time | Time elapsed from building the kernel in seconds, excluding zipping and downloading toolchains |
outfile | Path to the final build file |
hash | Kernel commit hash |
Put the AnyKernel3 template to zipper. Providing AnyKernel3 template is optional, the outfile output varies based on this. If AnyKernel3 template is provided, this Action will create a flashable zip file based on the AnyKernel3 template and the outfile output will be the path to the zipfile. if not the outfile will be the path to the kernel image. See the examples.
Use other action to actually get the file, for example, with ncipollo/release-action:
- name: Release builduses: ncipollo/release-action@v1with:
artifacts: ${{ steps.<step id>.outputs.outfile }}token: ${{ secrets.GITHUB_TOKEN }}Or with appleboy/telegram-action:
- name: Release builduses: appleboy/telegram-action@masterwith:
to: ${{ secrets.CHANNEL_ID }}token: ${{ secrets.TELEGRAM_BOT_TOKEN }}message: ${{ github.repository }} on ${{ github.sha }} is built!document: ${{ steps.<step id>.outputs.outfile }}If you want to compile with Clang and LLVM without any of GNU's binutils, make sure your kernel source already supports LLVM options, otherwise compilation may fails. In that case, use clang toolchain with /binutils.
gcc/7gcc/8gcc/9gcc/10
clang/6.0,clang/6.0/binutilsclang/7,clang/7/binutilsclang/8,clang/8/binutilsclang/9,clang/9/binutilsclang/10,clang/10/binutilsclang/11,clang/11/binutils
proton-clang/<branch, commit hash or tag>,proton-clang/<branch, commit hash or tag>/binutils
Example :
proton-clang/master,proton-clang/09fb113/binutils
aosp-clang/<branch>/<clang version>,aosp-clang/<branch>/<clang version>/binutils
Example :
aosp-clang/master/clang-r416183b,aosp-clang/android11-release/clang-r365631c/binutils
name: Build on Tagon:
push:
tags: '*'jobs:
build:
runs-on: ubuntu-lateststeps:
- name: Checkout kernel sourceuses: actions/checkout@v2
- name: Checkout zipperuses: actions/checkout@v2with:
repository: lemniskett/AnyKernel3path: zipper
- name: Android kernel builduses: lemniskett/android-kernel-actions@masterid: buildenv:
NAME: Dark-Ages-Últimowith:
arch: arm64compiler: gcc/10defconfig: vince_defconfigimage: Image.gz-dtb
- name: Release builduses: ncipollo/release-action@v1with:
artifacts: ${{ steps.build.outputs.outfile }}token: ${{ secrets.GITHUB_TOKEN }}name: Build on push masteron:
push:
branches: [ master ]jobs:
build:
runs-on: ubuntu-lateststeps:
- name: Checkout kernel sourceuses: actions/checkout@v2
- name: Checkout zipperuses: actions/checkout@v2with:
repository: lemniskett/AnyKernel3path: zipper
- name: Android kernel builduses: lemniskett/android-kernel-actions@masterid: buildenv:
NAME: Dark-Ages-Últimowith:
arch: arm64compiler: gcc/10defconfig: vince_defconfigimage: Image.gz-dtb
- name: Release builduses: appleboy/telegram-action@masterwith:
to: ${{ secrets.CHANNEL_ID }}token: ${{ secrets.TELEGRAM_BOT_TOKEN }}message: Kernel is built!, took ${{ steps.build.outputs.elapsed_time }} seconds.document: ${{ steps.build.outputs.outfile }}1: Packages fails to install2: .config fails to be generated3: Build fails100: Unsupported usage127: Unexpected error