Skip to content

Instantly share code, notes, and snippets.

@tdussa
Last active March 17, 2023 08:46
Show Gist options
  • Save tdussa/85da16d380e47cabf7f785027f30b8bb to your computer and use it in GitHub Desktop.
Save tdussa/85da16d380e47cabf7f785027f30b8bb to your computer and use it in GitHub Desktop.
How to convince the `pacmixer` AUR package to build

How to convince the pacmixer AUR package to build

When building the package, select cleanBuild, edit the PKGBUILD file and add this code verbatim right before the build() function:

prepare() {
    cd "${srcdir}/${pkgname}-${pkgver}"
    patch -p1 <<'EOF'    
From 82ef1fb08c0aec56999e89c8d355d74bdbf9788a Mon Sep 17 00:00:00 2001
From: FuzzyNovaGoblin <fuzzy.nova.goblin@outlook.com>
Date: Wed, 15 Feb 2023 18:44:07 -0500
Subject: [PATCH] add missing format string

---
 src/widgets/notice.m | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/widgets/notice.m b/src/widgets/notice.m
index 3f9584e..b94eaee 100644
--- a/src/widgets/notice.m
+++ b/src/widgets/notice.m
@@ -49,7 +49,7 @@
 -(void) print {
     wattron(win, A_REVERSE);
     box(win, 0, 0);
-    mvwprintw(win, 1, 1, [message UTF8String]);
+    mvwprintw(win, 1, 1, "%s", [message UTF8String]);
     wattroff(win, A_REVERSE);
 }
 
-- 
2.39.2
EOF
}

It might be necessary to convince your package manager to ask you whether you want to edit the PKGBUILD file. For yay, adding --editmenu to the command line does the trick:

yay -S --editmenu pacmixer
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment