Build Stoney Kernel on Arch

Greetings. I saw this post about building kernel for stoney but it’s for debian. I’m very new to Linux and am using Arch linux (largely to learn this all vigorously).

A step-by-step guide would be most appreciated but general guidance (reference to verified guides, etc) would also help

The arch wiki has a general guide for compiling your own kernel. Make sure you modify the PKGBUILD to include the patch file linked in the post you referenced.

I am stuck here and have no idea what’s the matter(text extracted by ChatGPT after I uploaded the picture to it)

==> Validating source files with b2sums...
    linux-6.16.5.tar.xz ... Passed
    linux-6.16.5.tar.sign ... Skipped
    linux-v6.16.5-arch1.patch.zst ... Passed
    linux-v6.16.5-arch1.patch.zst.sig ... Skipped
    config ... Passed
==> Verifying source file signatures with gpg...
    linux-6.16.5.tar ... Passed
    linux-v6.16.5-arch1.patch.zst ... Passed
==> Extracting sources...
  -> Extracting linux-6.16.5.tar.xz with bsdtar
  -> Extracting linux-v6.16.5-arch1.patch.zst with zstd
==> Starting prepare()...
Applying /home/mutawir01/build/linux-liquorix-stoney/src/../patches-liquorix/liquorix-stoney.patch
patching file linux-liquorix/debian/patches/chrultrabook/01-asoc-amd-use-new-acp-dev-names-for-dai-links.patch
patching file linux-liquorix/debian/patches/chrultrabook/02-drm-amdgpu-use-static-ids-for-acp-platform-devs.patch
can't find file to patch at input line 288
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:

--------------------------
|diff --git a/linux-liquorix/debian/patches/series b/linux-liquorix/debian/patches/series
|index 9c2b2092..3e53148c 100644
|--- a/linux-liquorix/debian/patches/series
|+++ b/linux-liquorix/debian/patches/series
--------------------------

File to patch: _

Perhaps it is because I am using Debian’s patch? (the one I saw in the post mentioned earlier)

These are what I modified in the PKGBUILD

pkgbase=linux-liquorix-stoney
pkgdesc=‘Linux kernel with Liquorix and Stoney Ridge support’
prepare() {
  cd $_srcname

  # Apply Liquorix & Stoney patches
  for p in "${srcdir}"/../patches-liquorix/*.patch; do
    echo "Applying $p"
    patch -Np1 -i "$p"
  done


  echo "Setting version..."
  echo "-$pkgrel" > localversion.10-pkgrel
  echo "${pkgbase#linux}" > localversion.20-pkgname

#  local src
#  for src in "${source[@]}"; do
#    src="${src%%::*}"
#    src="${src##*/}"
#    src="${src%.zst}"
#    [[ $src = *.patch ]] || continue
#    echo "Applying patch $src..."
#    patch -Np1 < "../$src"
#  done

  echo "Setting config..."
  cp ../config .config
  make olddefconfig
  diff -u ../config .config || :

  make -s kernelrelease > version
  echo "Prepared $pkgbase version $(<version)"
}

I’m not too sure what I did wrong. These are the two patches I added in “./patches-liquorix”

https://forum.chrultrabook.com/uploads/short-url/levr5lUJL1DBamyUwErgcYEQpph.patch

(also, I am new to forum-style stuff so let me if I am not providing enough info or giving irrelevant info, and thanks WeirdTreeThing for the guidance initially)

Why are you trying to use Liquorix on Arch? Arch Wiki page linked by WTT already has all required commands to get sources for your kernel and how to add patches.

Ahh… So Liquorix is not a patch? Since it was part of the post itself, I thought it was also a patch (or, more specifically, the patch inside zen folder in the patches) hence why I added it in the patches

May you kindly provide me with all the required patches? I wish to avoid making this kind of stupid mistake again