Linux kernel 5.15.161 LTS #245
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: S905D KERNEL CI | |
on: | |
release: | |
types: published | |
push: | |
branches: | |
- master | |
paths: | |
- ".config" | |
- ".github/workflows/main.yml" | |
- "patch/**" | |
watch: | |
types: [started] | |
env: | |
BUILD_DIR: /tmp/ramfs | |
KVER: 5.15.161 | |
ARCH: arm64 | |
CROSS_COMPILE: /opt/toolchain/bin/aarch64-none-linux-gnu- | |
LOCALVERSION: -aml-s905d-starx-action | |
jobs: | |
build: | |
runs-on: ubuntu-24.04 | |
if: github.event.repository.owner.id == github.event.sender.id | |
steps: | |
- name: Checkout | |
uses: actions/[email protected] | |
- name: Host info | |
run: | | |
pwd | |
lscpu | |
free -h | |
df -h | |
- name: Install requirements | |
run: | | |
sudo apt-get update | |
sudo apt-get install -y git fakeroot build-essential ncurses-dev xz-utils libssl-dev bc flex libelf-dev bison libncurses-dev autoconf dkms libudev-dev libpci-dev libiberty-dev u-boot-tools lzop | |
- name: Clone Repos | |
run: bash setup_new_kernel.sh $KVER | |
- name: Install cross compile toolchain | |
run: bash setup_aarch64_toolchain.sh | |
- name: Apply patchs | |
run: | | |
cd /tmp/ramfs/build/linux-$KVER | |
cp -r $GITHUB_WORKSPACE/patch . | |
for p in `ls patch`; do patch --ignore-whitespace -t -p1 -N < patch/$p; done | |
- name: Build Kernel | |
run: | | |
cd /tmp/ramfs/build/linux-$KVER | |
cp $GITHUB_WORKSPACE/.config .config | |
make -j$(nproc) oldconfig | |
make -j$(nproc) bindeb-pkg | |
- name: Extract Binaries | |
run: | | |
cd /tmp/ramfs/build/linux-$KVER | |
cp arch/arm64/boot/Image $GITHUB_WORKSPACE | |
cp arch/arm64/boot/dts/amlogic/*.dtb $GITHUB_WORKSPACE | |
rsync -a ../*$KVER* --exclude=linux-$KVER $GITHUB_WORKSPACE | |
- uses: actions/[email protected] | |
with: | |
name: Kernel ${{ env.KVER }} | |
path: | | |
install_kernel.sh | |
Image | |
*${{ env.KVER }}* | |
.config | |
*.dtb | |
- name: ZIP FILES | |
run: | | |
cd $GITHUB_WORKSPACE | |
zip data.zip install_kernel.sh Image *${{ env.KVER }}* .config *.dtb | |
- name: Create Release | |
id: create_release | |
uses: actions/[email protected] | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
tag_name: ${{ env.KVER }} | |
release_name: Linux Kernel ${{ env.KVER }} | |
draft: false | |
prerelease: false | |
- name: Upload Release Asset | |
id: upload-release-asset | |
uses: actions/[email protected] | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
upload_url: ${{ steps.create_release.outputs.upload_url }} | |
asset_path: ./data.zip | |
asset_name: Kernel ${{ env.KVER }}.zip | |
asset_content_type: application/zip |