diff --git a/anda/others/kernel-fyra/anda.hcl b/anda/others/kernel-fyra/anda.hcl new file mode 100644 index 0000000000..a6c49804f9 --- /dev/null +++ b/anda/others/kernel-fyra/anda.hcl @@ -0,0 +1,3 @@ +project pkg { + arches = ["x86_64", "aarch64"] +} \ No newline at end of file diff --git a/anda/others/kernel-fyra/build.sh b/anda/others/kernel-fyra/build.sh new file mode 100644 index 0000000000..3b707f3b65 --- /dev/null +++ b/anda/others/kernel-fyra/build.sh @@ -0,0 +1,55 @@ +#!/bin/sh + +# Set the kernel-ark release build rev number +export KERNEL_ARK_REV='200' + +# Set the Fyra kernel overlay version +export FYRA_KERNELOVERLAY_VER='2' + +# Fetch the patches +git clone https://github.com/FyraLabs/linux-kernel-patches.git patches + +# Move into the patches' directory +pushd patches + +# Acquire the latest supported kernel-ark branch +export BRANCH="$(readlink current)" + +# Move out from the patches' directory +popd + +# Fetch the source +git clone -b ${BRANCH} https://gitlab.com/cki-project/kernel-ark.git source + +# Move into the source directory +pushd source + +# Set proper user name for commits +git config user.name 'Terra' ; git config user.email 'mail@example.com' + +# Apply all patches +for patch in ../patches/${BRANCH}/*.patch + do git am $patch +done + +# Build the SRPM +make \ + IS_FEDORA=1 \ + BUILD=${KERNEL_ARK_REV} \ + SPECPACKAGE_NAME='kernel-fyra' \ + DISTLOCALVERSION=".fyra${FYRA_KERNELOVERLAY_VER}" \ + dist-srpm -j$(nproc) + +# Build the resulting SRPM +rpmbuild -rb \ + --without=debug \ + --without=configchecks \ + redhat/rpm/SRPMS/kernel-fyra-*.src.rpm + +# Move the resulting SRPM into the target directory +for file in redhat/rpm/RPMS/*.rpm + do mv -v $file ../anda-build/rpm/rpms/ +done + +# We're done here +exit 0 diff --git a/anda/others/kernel-fyra/pre.rhai b/anda/others/kernel-fyra/pre.rhai new file mode 100644 index 0000000000..5e6ac8e901 --- /dev/null +++ b/anda/others/kernel-fyra/pre.rhai @@ -0,0 +1,8 @@ +// Install the kernel dependencies first +sh("sudo dnf5 builddep kernel") + +// Install git for source and patchset retrieval +sh("sudo dnf5 install git") + +// Run the actual build script +sh("build.sh") \ No newline at end of file