summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorIvy Foster2017-05-24 15:11:19 -0500
committerIvy Foster2017-05-24 15:11:19 -0500
commit9691c9b3fe1a7219a2c714ccb058347c917b6dd9 (patch)
treee75390c7c6c3a9bcebd6bcb19d11bb4043dd134d
downloadaur-9691c9b3fe1a7219a2c714ccb058347c917b6dd9.tar.gz
initial commit
-rw-r--r--.SRCINFO16
-rw-r--r--0001-put-cookie-somewhere-better.patch34
-rw-r--r--PKGBUILD33
3 files changed, 83 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..30e6b14d29d
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,16 @@
+pkgbase = sndio-git
+ pkgdesc = A small audio and MIDI framework part of the OpenBSD project
+ pkgver = 1.0.1.r123.f8436a7
+ pkgrel = 1
+ url = http://www.sndio.org
+ arch = i686
+ arch = x86_64
+ license = MIT
+ provides = sndio
+ source = git+http://caoua.org/git/sndio
+ source = 0001-put-cookie-somewhere-better.patch
+ md5sums = SKIP
+ md5sums = SKIP
+
+pkgname = sndio-git
+
diff --git a/0001-put-cookie-somewhere-better.patch b/0001-put-cookie-somewhere-better.patch
new file mode 100644
index 00000000000..a7a0e12cae5
--- /dev/null
+++ b/0001-put-cookie-somewhere-better.patch
@@ -0,0 +1,34 @@
+From 020bd1da2875b573862b333a4a7d13cbdfd94fea Mon Sep 17 00:00:00 2001
+From: Ivy Foster <ivy.foster@gmail.com>
+Date: Wed, 1 Feb 2017 14:17:52 -0600
+Subject: [PATCH] put cookie somewhere better
+
+---
+ libsndio/aucat.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/libsndio/aucat.c b/libsndio/aucat.c
+index 10ddce4..9dfad79 100644
+--- a/libsndio/aucat.c
++++ b/libsndio/aucat.c
+@@ -244,7 +244,7 @@ _aucat_wdata(struct aucat *hdl, const void *buf, size_t len,
+ static int
+ aucat_mkcookie(unsigned char *cookie)
+ {
+-#define COOKIE_SUFFIX "/.aucat_cookie"
++#define COOKIE_SUFFIX "/aucat_cookie"
+ #define TEMPL_SUFFIX ".XXXXXXXX"
+ struct stat sb;
+ char *home, *path = NULL, *tmp = NULL;
+@@ -257,7 +257,7 @@ aucat_mkcookie(unsigned char *cookie)
+ /*
+ * try to load the cookie
+ */
+- home = issetugid() ? NULL : getenv("HOME");
++ home = issetugid() ? NULL : getenv("XDG_CACHE_HOME");
+ if (home == NULL)
+ goto bad_gen;
+ home_len = strlen(home);
+--
+2.11.0
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..8b5880179e7
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,33 @@
+# Maintainer: Ivy Foster <ivy.foster@gmail.com>
+
+pkgname='sndio-git'
+pkgver=1.0.1.r123.f8436a7
+pkgrel=1
+pkgdesc='A small audio and MIDI framework part of the OpenBSD project'
+arch=('i686' 'x86_64')
+url='http://www.sndio.org'
+license=('MIT')
+provides=('sndio')
+source=('git+http://caoua.org/git/sndio' '0001-put-cookie-somewhere-better.patch')
+md5sums=('SKIP' 'SKIP')
+
+pkgver() {
+ cd sndio
+ git describe | sed 's,release_,,; s,_,.,g; s,-\(.*\)-.,.r\1.,'
+}
+
+prepare() {
+ cd sndio
+ git apply ../0001-put-cookie-somewhere-better.patch
+}
+
+build() {
+ cd sndio
+ ./configure --prefix=/usr --enable-alsa
+ make
+ make -C libsndio libsndio.so
+}
+
+package() {
+ make -C sndio DESTDIR="$pkgdir/" install
+}