Skip to content

Instantly share code, notes, and snippets.

@SirToffski
Last active July 14, 2022 16:37
Show Gist options
  • Save SirToffski/be41fa9a7e2a2629fad811da80f1a685 to your computer and use it in GitHub Desktop.
Save SirToffski/be41fa9a7e2a2629fad811da80f1a685 to your computer and use it in GitHub Desktop.
slippi-arch-linux.md

AUR Helper


It's possible to install everything from AUR without using the helper, however that's not very conveniet. See here for some common ones: https://wiki.archlinux.org/title/AUR_helpers

yay and paru are commonly used AUR helpers. I use paru so this guide will use it as well.

Installing paru


Upstream paru repository is here: https://github.com/Morganamilo/paru

To insall it:

sudo pacman -S --needed base-devel
git clone https://aur.archlinux.org/paru.git
cd paru
makepkg -si

paru accepts more or less the same flags as pacman - so basic usage would be very similar.

Installing Slippi

Once paru has been installed - slippi can be installed from AUR. I've tested two packages so far:

  • slippi-online-git - build slippi Dolhin from source. Works quite well. However it does not include the Launcher.
  • slippi-launcher - installs tha Launcher + netplay Dolphin + replay Dolphin + gc controller adapter.

slippi-online-git - could be an interesting choice if you'd want to try building it using optimized C-flags for your CPU architecture. However I had not tested it and custom c-flags are very likely not at all supported. You'd also need to manually configure GC controller adapter. slippi-launcher - likely the best all-in-one solution; probably the one I would recommend.

To install either of the above (I am using slippi-launcher as an example):

$ paru -S slippi-launcher --noconfirm

⚠️ If your DE is using Wayland: I had not been able to get slippi-dolhin to launch on Wayland at all. Simply switching to Xorg solves the problem.

Overclocking GC Adapter

Overclocking is quite trivial as well. HannesMann had packaged the kernel mod for Arch. For more info, check out https://github.com/HannesMann/gcadapter-oc-kmod

DKMS and Kernel Headers

First, make sure kernel headers and DKMS are installed.

To find out which kernel is currently running, one could use cat /proc/version. The naming convention is kernel_name-headers. For example:

image

A faster, though possibly less reliable way would be to use something like pacman -Qq | grep "$(cat /proc/version | awk '{print $4}' | sed -r 's/\(|@.*//g')", for example:

$ pacman -Qq | grep "$(cat /proc/version | awk '{print $4}' | sed -r 's/\(|@.*//g')"
linux-zen
linux-zen-headers

If you do not see the headers intalled, install them alongside with DKMS. Here are some examples for commonly used kernels:

# If your kernel is 'linux'
$ sudo pacman -S linux-headers dkms --needed

# If your kernel is 'linux-zen'
$ sudo pacman -S linux-zen-headers dkms --needed

# If your kernel is 'linux-clear', it's not available in official repositories, use paru to get it from AUR
$ paru -S linux-clear-headers dkms --needed

Installing gcadapter-oc-kmod

Once headers and DKMS are confirmed to be intalled, download the gcadapter-oc-dkms package and insall it with pacman. For example with wget:

$ wget --https-only 'https://github.com/HannesMann/gcadapter-oc-kmod/releases/download/v1.4/gcadapter-oc-dkms-1.4-1-any.pkg.tar.zst'
$ sudo pacman -U gcadapter-oc-dkms-1.4-1-any.pkg.tar.zst

With the above package, dkms will make sure the kmod is applied for newly installed kernels and kernel updates.

To load the kmod:

$ sudo modprobe gcadapter_oc

Once loaded, poll rate can be changed like this:

$ cd /sys/module/gcadapter_oc/parameters

# 1000Hz
$ echo '1' | sudo tee rate

# 500Hz
$ echo '2' | sudo tee rate

# 250Hz
$ echo '4' | sudo tee rate

# To set to default (125Hz) - unload the kmod
$ sudo modprobe -r gcadapter_oc

Happy gaming!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment