Skip to content

Instantly share code, notes, and snippets.

Avatar

Christopher Snowhill kode54

View GitHub Profile
@kode54
kode54 / myconfig
Created Sep 21, 2021
My xanmod config - goes in ~/.config/linux-xanmod/myconfig
View myconfig
scripts/config --enable CONFIG_ASHMEM
scripts/config --enable CONFIG_ANDROID
scripts/config --enable CONFIG_ANDROID_BINDER_IPC
scripts/config --enable CONFIG_ANDROID_BINDERFS
scripts/config --set-str CONFIG_ANDROID_BINDER_DEVICES "binder,hwbinder,vndbinder"
scripts/config --enable CONFIG_LTO_CLANG_FULL
@kode54
kode54 / Dolphin_cmake_prefix.patch
Last active May 3, 2021
CMake build script patch for Dolphin, PR# 9441
View Dolphin_cmake_prefix.patch
From a51d9cdde1774fd2c86ec3db4d85f5b7b036f2d9 Mon Sep 17 00:00:00 2001
From: Christopher Snowhill <kode54@gmail.com>
Date: Sun, 2 May 2021 17:59:06 -0700
Subject: [PATCH] Apple M1: Implement CMake Prefix Path override
Fixes issues, if, for instance, the `fmt` package is installed by Homebrew.
---
BuildMacOSUniversalBinary.py | 13 +++++++++++++
1 file changed, 13 insertions(+)
@kode54
kode54 / pcem_apple_silicon.patch
Created Apr 20, 2021
PCem patch to get things working on Apple Silicon, partially at least
View pcem_apple_silicon.patch
diff --git a/configure.ac b/configure.ac
index 407b057..b237e9e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -72,6 +72,9 @@ case "${host_cpu}" in
CPU=arm64
AC_MSG_RESULT(${host_cpu})
;;
+ arm)
+ CPU=arm64 # MacOS has "arm" in the host string
@kode54
kode54 / exhale_universal2_workdir.patch
Created Mar 27, 2021
Exhale Universal 2 (plus enable working directory change)
View exhale_universal2_workdir.patch
diff --git a/makefile b/makefile
index 924d4f3..94cc0ee 100644
--- a/makefile
+++ b/makefile
@@ -11,20 +11,24 @@
## BUILD32=1: compile for 32-bit platforms, BUILD32=0: compile for 64-bit platforms
BUILD32?=0
+## UNIVERSAL2=1: compile for both x86_64 and arm64 on macOS, UNIVERSAL2=0: compile for native architecture on all platforms
+UNIVERSAL2?=0
@kode54
kode54 / README.md
Last active Oct 21, 2020
Quick and dirty fix for Linux apps that don't natively support webcam formats other than raw pixels
View README.md

This is a simple setup. Basically, you just need to install v4l2loopback for your kernel, sometimes a DKMS module.

Run this to load it manually, if it isn't automatically loaded and configured in your /etc settings:

sudo modprobe v4l2loopback exclusive_caps=1 card_label=<camera label>

For camera label, I went with "camerafun" but any alphanumeric string will work. This will be the name of the video source.

@kode54
kode54 / pkgbuild.patch
Created Feb 17, 2020
OpenCL-AMD PKGBUILD patch
View pkgbuild.patch
diff --git a/PKGBUILD b/PKGBUILD
index aeb66ed..73f4e1d 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,7 +2,7 @@
pkgname=opencl-amd
pkgdesc="OpenCL userspace driver as provided in the amdgpu-pro driver stack. This package is intended to work along with the free amdgpu stack."
-pkgver=19.30.934563
+pkgver=19.50.967956
@kode54
kode54 / hesuvi_convert.c
Last active Feb 25, 2021
This fairly simple tool converts all HeSuVi 14 channel presets into 7.0 formatted _L/_R stereo pairs, for use with the soon to be updated PulseAudio module-virtual-surround-sink, which I've updated with a faster FFT overlap-save convolver, eliminated the sample length limits for impulses, and added support for asymmetrical/dual impulse mode.
View hesuvi_convert.c
#include <stdio.h>
#include <stdlib.h>
#include <stdint.h>
#include <string.h>
#define SPEAKER_FRONT_LEFT 0x1
#define SPEAKER_FRONT_RIGHT 0x2
#define SPEAKER_FRONT_CENTER 0x4
#define SPEAKER_LFE 0x8
#define SPEAKER_BACK_LEFT 0x10
View pulseaudio_virtual-surround_fftw.patch
diff -urN pulseaudio.orig/src/modules/meson.build pulseaudio/src/modules/meson.build
--- pulseaudio.orig/src/modules/meson.build 2020-01-18 00:13:15.288900614 -0800
+++ pulseaudio/src/modules/meson.build 2020-01-18 17:57:26.855466531 -0800
@@ -61,7 +61,6 @@
[ 'module-tunnel-source-new', 'module-tunnel-source-new.c' ],
[ 'module-virtual-sink', 'module-virtual-sink.c' ],
[ 'module-virtual-source', 'module-virtual-source.c' ],
- [ 'module-virtual-surround-sink', 'module-virtual-surround-sink.c' ],
[ 'module-volume-restore', 'module-volume-restore.c' ],
# [ 'module-waveout', 'module-waveout.c' ],
View gist:d3e729ec47cd5bdfba2f82790f91ec21
06:56 <%Mardeg> 0-pooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooo
06:56 <%Mardeg> p0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000ppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppp000000000000000000000000000000000000000000000000000000000000000000000000000
06:56 <%Mardeg> 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
@kode54
kode54 / Cpu features.txt
Last active Nov 15, 2019
Conclusion: it’s probably not the processor feature bits, re: hackintosh drm working on Ryzen 3rd gen
View Cpu features.txt
machdep.cpu.feature_bits:
9140110466969500671
machdep.cpu.leaf7_feature_bits:
563909033
4194308
machdep.cpu.extfeature_bits:
8485406217078045695
machdep.cpu.features:
FPU
VME