summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--media-sound/pulseaudio/ChangeLog7
-rw-r--r--media-sound/pulseaudio/files/pulseaudio-0.9.2-fbsd.patch44
2 files changed, 33 insertions, 18 deletions
diff --git a/media-sound/pulseaudio/ChangeLog b/media-sound/pulseaudio/ChangeLog
index 30eb49fd7ce5..554a329dfdf0 100644
--- a/media-sound/pulseaudio/ChangeLog
+++ b/media-sound/pulseaudio/ChangeLog
@@ -1,6 +1,11 @@
# ChangeLog for media-sound/pulseaudio
# Copyright 1999-2006 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/media-sound/pulseaudio/ChangeLog,v 1.4 2006/07/16 21:37:25 flameeyes Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-sound/pulseaudio/ChangeLog,v 1.5 2006/07/16 23:33:00 flameeyes Exp $
+
+ 16 Jul 2006; Diego Pettenò <flameeyes@gentoo.org>
+ files/pulseaudio-0.9.2-fbsd.patch:
+ Improve FreeBSD patch a bit thanks to suggestion of the author Lennart
+ Poettering.
16 Jul 2006; Diego Pettenò <flameeyes@gentoo.org>
pulseaudio-0.9.2.ebuild:
diff --git a/media-sound/pulseaudio/files/pulseaudio-0.9.2-fbsd.patch b/media-sound/pulseaudio/files/pulseaudio-0.9.2-fbsd.patch
index 729bd75b82b5..478c8f5fa5ca 100644
--- a/media-sound/pulseaudio/files/pulseaudio-0.9.2-fbsd.patch
+++ b/media-sound/pulseaudio/files/pulseaudio-0.9.2-fbsd.patch
@@ -24,7 +24,7 @@ Index: pulseaudio-0.9.2/src/utils/padsp.c
#include <dlfcn.h>
#include <errno.h>
#include <fcntl.h>
-@@ -44,7 +45,9 @@
+@@ -44,12 +45,19 @@
#include <stdio.h>
#include <signal.h>
@@ -34,7 +34,17 @@ Index: pulseaudio-0.9.2/src/utils/padsp.c
#include <pulse/pulseaudio.h>
#include <pulsecore/llist.h>
-@@ -101,8 +104,10 @@ static int (*_ioctl)(int, int, void*) =
+ #include <pulsecore/gccmacro.h>
+
++/* On some systems SIOCINQ isn't defined, but FIONREAD is just an alias */
++#if !defined(SIOCINQ) && defined(FIONREAD)
++# define SIOCINQ FIONREAD
++#endif
++
+ typedef enum {
+ FD_INFO_MIXER,
+ FD_INFO_STREAM,
+@@ -101,8 +109,10 @@ static int (*_ioctl)(int, int, void*) =
static int (*_close)(int) = NULL;
static int (*_open)(const char *, int, mode_t) = NULL;
static FILE* (*_fopen)(const char *path, const char *mode) = NULL;
@@ -45,7 +55,7 @@ Index: pulseaudio-0.9.2/src/utils/padsp.c
static int (*_fclose)(FILE *f) = NULL;
static int (*_access)(const char *, int) = NULL;
-@@ -1302,7 +1307,11 @@ static int sndstat_open(int flags, int *
+@@ -1302,7 +1312,11 @@ static int sndstat_open(int flags, int *
debug(DEBUG_LEVEL_NORMAL, __FILE__": sndstat_open()\n");
@@ -58,7 +68,7 @@ Index: pulseaudio-0.9.2/src/utils/padsp.c
*_errno = EACCES;
debug(DEBUG_LEVEL_NORMAL, __FILE__": bad access!\n");
goto fail;
-@@ -1349,8 +1358,12 @@ int open(const char *filename, int flags
+@@ -1349,8 +1363,12 @@ int open(const char *filename, int flags
debug(DEBUG_LEVEL_VERBOSE, __FILE__": open(%s)\n", filename);
va_start(args, flags);
@@ -72,7 +82,7 @@ Index: pulseaudio-0.9.2/src/utils/padsp.c
va_end(args);
if (!function_enter()) {
-@@ -1587,6 +1600,7 @@ static int map_format_back(pa_sample_for
+@@ -1587,6 +1605,7 @@ static int map_format_back(pa_sample_for
}
static int dsp_flush_fd(int fd) {
@@ -80,7 +90,7 @@ Index: pulseaudio-0.9.2/src/utils/padsp.c
int l;
if (ioctl(fd, SIOCINQ, &l) < 0) {
-@@ -1605,6 +1619,10 @@ static int dsp_flush_fd(int fd) {
+@@ -1605,6 +1624,10 @@ static int dsp_flush_fd(int fd) {
}
return 0;
@@ -91,7 +101,7 @@ Index: pulseaudio-0.9.2/src/utils/padsp.c
}
static int dsp_flush_socket(fd_info *i) {
-@@ -1629,6 +1647,7 @@ static int dsp_flush_socket(fd_info *i)
+@@ -1629,6 +1652,7 @@ static int dsp_flush_socket(fd_info *i)
}
static int dsp_empty_socket(fd_info *i) {
@@ -99,7 +109,7 @@ Index: pulseaudio-0.9.2/src/utils/padsp.c
int ret = -1;
/* Empty the socket */
-@@ -1652,6 +1671,10 @@ static int dsp_empty_socket(fd_info *i)
+@@ -1652,6 +1676,10 @@ static int dsp_empty_socket(fd_info *i)
}
return ret;
@@ -110,7 +120,7 @@ Index: pulseaudio-0.9.2/src/utils/padsp.c
}
static int dsp_drain(fd_info *i) {
-@@ -1864,7 +1887,11 @@ static int dsp_ioctl(fd_info *i, unsigne
+@@ -1864,7 +1892,11 @@ static int dsp_ioctl(fd_info *i, unsigne
case SNDCTL_DSP_GETCAPS:
debug(DEBUG_LEVEL_NORMAL, __FILE__": SNDCTL_DSP_CAPS\n");
@@ -123,7 +133,7 @@ Index: pulseaudio-0.9.2/src/utils/padsp.c
break;
case SNDCTL_DSP_GETODELAY: {
-@@ -1895,11 +1922,15 @@ static int dsp_ioctl(fd_info *i, unsigne
+@@ -1895,11 +1927,15 @@ static int dsp_ioctl(fd_info *i, unsigne
}
exit_loop:
@@ -140,7 +150,7 @@ Index: pulseaudio-0.9.2/src/utils/padsp.c
pa_threaded_mainloop_unlock(i->mainloop);
-@@ -1946,7 +1977,7 @@ static int dsp_ioctl(fd_info *i, unsigne
+@@ -1946,7 +1982,7 @@ static int dsp_ioctl(fd_info *i, unsigne
case SNDCTL_DSP_GETOSPACE:
case SNDCTL_DSP_GETISPACE: {
audio_buf_info *bi = (audio_buf_info*) argp;
@@ -149,7 +159,7 @@ Index: pulseaudio-0.9.2/src/utils/padsp.c
size_t k = 0;
if (request == SNDCTL_DSP_GETOSPACE)
-@@ -1965,10 +1996,14 @@ static int dsp_ioctl(fd_info *i, unsigne
+@@ -1965,10 +2001,14 @@ static int dsp_ioctl(fd_info *i, unsigne
} else
k = i->fragment_size * i->n_fragments;
@@ -164,7 +174,7 @@ Index: pulseaudio-0.9.2/src/utils/padsp.c
bi->bytes = k > (size_t) l ? k - l : 0;
} else {
-@@ -1978,11 +2013,14 @@ static int dsp_ioctl(fd_info *i, unsigne
+@@ -1978,11 +2018,14 @@ static int dsp_ioctl(fd_info *i, unsigne
} else
k = 0;
@@ -180,7 +190,7 @@ Index: pulseaudio-0.9.2/src/utils/padsp.c
bi->bytes = k + l;
}
-@@ -2104,6 +2142,8 @@ int access(const char *pathname, int mod
+@@ -2104,6 +2147,8 @@ int access(const char *pathname, int mod
return 0;
}
@@ -189,7 +199,7 @@ Index: pulseaudio-0.9.2/src/utils/padsp.c
int open64(const char *filename, int flags, ...) {
va_list args;
mode_t mode = 0;
-@@ -2126,6 +2166,8 @@ int open64(const char *filename, int fla
+@@ -2126,6 +2171,8 @@ int open64(const char *filename, int fla
return open(filename, flags, mode);
}
@@ -198,7 +208,7 @@ Index: pulseaudio-0.9.2/src/utils/padsp.c
FILE* fopen(const char *filename, const char *mode) {
FILE *f = NULL;
int fd;
-@@ -2168,6 +2210,8 @@ FILE* fopen(const char *filename, const
+@@ -2168,6 +2215,8 @@ FILE* fopen(const char *filename, const
return f;
}
@@ -207,7 +217,7 @@ Index: pulseaudio-0.9.2/src/utils/padsp.c
FILE *fopen64(const char *filename, const char *mode) {
debug(DEBUG_LEVEL_VERBOSE, __FILE__": fopen64(%s)\n", filename);
-@@ -2183,6 +2227,8 @@ FILE *fopen64(const char *filename, cons
+@@ -2183,6 +2232,8 @@ FILE *fopen64(const char *filename, cons
return fopen(filename, mode);
}