diff options
author | jmcneill <jmcneill> | 2010-02-01 15:00:20 +0000 |
---|---|---|
committer | jmcneill <jmcneill> | 2010-02-01 15:00:20 +0000 |
commit | 675ada910f816c13f1976ea04835f084a17e2f96 (patch) | |
tree | 6690fa66065a5b1d0f475cbd255c6d1550a826e2 /audio/pulseaudio/patches | |
parent | 60a61ae3b1aa0bb77869a2187e8ed768c2260ad5 (diff) | |
download | pkgsrc-675ada910f816c13f1976ea04835f084a17e2f96.tar.gz |
Update pulseaudio to 0.9.21.
Too many changes to list here:
http://pulseaudio.org/milestone/0.9.15
http://pulseaudio.org/milestone/0.9.16
http://pulseaudio.org/milestone/0.9.17
http://pulseaudio.org/milestone/0.9.18
http://pulseaudio.org/milestone/0.9.19
http://pulseaudio.org/milestone/0.9.20
http://pulseaudio.org/milestone/0.9.21
Diffstat (limited to 'audio/pulseaudio/patches')
-rw-r--r-- | audio/pulseaudio/patches/patch-aa | 36 | ||||
-rw-r--r-- | audio/pulseaudio/patches/patch-ab | 35 | ||||
-rw-r--r-- | audio/pulseaudio/patches/patch-ac | 42 | ||||
-rw-r--r-- | audio/pulseaudio/patches/patch-ad | 23 | ||||
-rw-r--r-- | audio/pulseaudio/patches/patch-ae | 37 | ||||
-rw-r--r-- | audio/pulseaudio/patches/patch-af | 22 | ||||
-rw-r--r-- | audio/pulseaudio/patches/patch-ag | 32 | ||||
-rw-r--r-- | audio/pulseaudio/patches/patch-ca | 6 | ||||
-rw-r--r-- | audio/pulseaudio/patches/patch-da | 45 | ||||
-rw-r--r-- | audio/pulseaudio/patches/patch-db | 15 | ||||
-rw-r--r-- | audio/pulseaudio/patches/patch-dc | 16 |
11 files changed, 175 insertions, 134 deletions
diff --git a/audio/pulseaudio/patches/patch-aa b/audio/pulseaudio/patches/patch-aa index 23f1ad8c002..d63398476da 100644 --- a/audio/pulseaudio/patches/patch-aa +++ b/audio/pulseaudio/patches/patch-aa @@ -1,8 +1,8 @@ -$NetBSD: patch-aa,v 1.5 2009/01/19 14:19:00 jmcneill Exp $ +$NetBSD: patch-aa,v 1.6 2010/02/01 15:00:20 jmcneill Exp $ ---- src/utils/padsp.c.orig 2009-01-12 18:10:34.000000000 -0500 -+++ src/utils/padsp.c 2009-01-19 08:09:05.000000000 -0500 -@@ -59,6 +59,10 @@ +--- src/utils/padsp.c.orig 2009-09-18 20:21:44.000000000 +0000 ++++ src/utils/padsp.c +@@ -60,6 +60,10 @@ # define SIOCINQ FIONREAD #endif @@ -13,7 +13,7 @@ $NetBSD: patch-aa,v 1.5 2009/01/19 14:19:00 jmcneill Exp $ /* make sure gcc doesn't redefine open and friends as macros */ #undef open #undef open64 -@@ -114,7 +118,11 @@ static pthread_mutex_t func_mutex = PTHR +@@ -115,7 +119,11 @@ static pthread_mutex_t func_mutex = PTHR static PA_LLIST_HEAD(fd_info, fd_infos) = NULL; @@ -25,7 +25,7 @@ $NetBSD: patch-aa,v 1.5 2009/01/19 14:19:00 jmcneill Exp $ static int (*_close)(int) = NULL; static int (*_open)(const char *, int, mode_t) = NULL; static FILE* (*_fopen)(const char *path, const char *mode) = NULL; -@@ -140,6 +148,15 @@ static inline fnptr dlsym_fn(void *handl +@@ -141,6 +149,15 @@ static inline fnptr dlsym_fn(void *handl return (fnptr) (long) dlsym(handle, symbol); } @@ -41,7 +41,7 @@ $NetBSD: patch-aa,v 1.5 2009/01/19 14:19:00 jmcneill Exp $ #define LOAD_IOCTL_FUNC() \ do { \ pthread_mutex_lock(&func_mutex); \ -@@ -147,6 +164,7 @@ do { \ +@@ -148,6 +165,7 @@ do { \ _ioctl = (int (*)(int, int, void*)) dlsym_fn(RTLD_NEXT, "ioctl"); \ pthread_mutex_unlock(&func_mutex); \ } while(0) @@ -49,7 +49,7 @@ $NetBSD: patch-aa,v 1.5 2009/01/19 14:19:00 jmcneill Exp $ #define LOAD_OPEN_FUNC() \ do { \ -@@ -180,11 +198,16 @@ do { \ +@@ -181,11 +199,16 @@ do { \ pthread_mutex_unlock(&func_mutex); \ } while(0) @@ -67,7 +67,7 @@ $NetBSD: patch-aa,v 1.5 2009/01/19 14:19:00 jmcneill Exp $ pthread_mutex_unlock(&func_mutex); \ } while(0) -@@ -1452,7 +1475,8 @@ static int real_open(const char *filenam +@@ -1458,7 +1481,8 @@ static int real_open(const char *filenam return _open(filename, flags, mode); } @@ -77,7 +77,7 @@ $NetBSD: patch-aa,v 1.5 2009/01/19 14:19:00 jmcneill Exp $ r = dsp_open(flags, &_errno); else if (filename && mixer_cloak_enable() && strcmp(filename, "/dev/mixer") == 0) r = mixer_open(flags, &_errno); -@@ -2313,19 +2337,27 @@ fail: +@@ -2319,19 +2343,27 @@ fail: #ifdef sun int ioctl(int fd, int request, ...) { @@ -105,7 +105,7 @@ $NetBSD: patch-aa,v 1.5 2009/01/19 14:19:00 jmcneill Exp $ if (!function_enter()) { LOAD_IOCTL_FUNC(); -@@ -2384,6 +2416,8 @@ int access(const char *pathname, int mod +@@ -2390,6 +2422,8 @@ int access(const char *pathname, int mod if (!pathname || (strcmp(pathname, "/dev/dsp") != 0 && strcmp(pathname, "/dev/adsp") != 0 && @@ -114,7 +114,7 @@ $NetBSD: patch-aa,v 1.5 2009/01/19 14:19:00 jmcneill Exp $ strcmp(pathname, "/dev/sndstat") != 0 && strcmp(pathname, "/dev/mixer") != 0 )) { LOAD_ACCESS_FUNC(); -@@ -2412,6 +2446,8 @@ int stat(const char *pathname, struct st +@@ -2418,6 +2452,8 @@ int stat(const char *pathname, struct st if (!pathname || !buf || ( strcmp(pathname, "/dev/dsp") != 0 && @@ -123,7 +123,7 @@ $NetBSD: patch-aa,v 1.5 2009/01/19 14:19:00 jmcneill Exp $ strcmp(pathname, "/dev/adsp") != 0 && strcmp(pathname, "/dev/sndstat") != 0 && strcmp(pathname, "/dev/mixer") != 0 )) { -@@ -2469,6 +2505,8 @@ int stat64(const char *pathname, struct +@@ -2475,6 +2511,8 @@ int stat64(const char *pathname, struct if (!pathname || !buf || ( strcmp(pathname, "/dev/dsp") != 0 && @@ -132,7 +132,7 @@ $NetBSD: patch-aa,v 1.5 2009/01/19 14:19:00 jmcneill Exp $ strcmp(pathname, "/dev/adsp") != 0 && strcmp(pathname, "/dev/sndstat") != 0 && strcmp(pathname, "/dev/mixer") != 0 )) { -@@ -2514,6 +2552,8 @@ int open64(const char *filename, int fla +@@ -2520,6 +2558,8 @@ int open64(const char *filename, int fla if (!filename || ( strcmp(filename, "/dev/dsp") != 0 && @@ -141,7 +141,7 @@ $NetBSD: patch-aa,v 1.5 2009/01/19 14:19:00 jmcneill Exp $ strcmp(filename, "/dev/adsp") != 0 && strcmp(filename, "/dev/sndstat") != 0 && strcmp(filename, "/dev/mixer") != 0 )) { -@@ -2534,6 +2574,8 @@ int __xstat(int ver, const char *pathnam +@@ -2540,6 +2580,8 @@ int __xstat(int ver, const char *pathnam if (!pathname || !buf || ( strcmp(pathname, "/dev/dsp") != 0 && @@ -150,7 +150,7 @@ $NetBSD: patch-aa,v 1.5 2009/01/19 14:19:00 jmcneill Exp $ strcmp(pathname, "/dev/adsp") != 0 && strcmp(pathname, "/dev/sndstat") != 0 && strcmp(pathname, "/dev/mixer") != 0 )) { -@@ -2557,6 +2599,8 @@ int __xstat64(int ver, const char *pathn +@@ -2563,6 +2605,8 @@ int __xstat64(int ver, const char *pathn if (!pathname || !buf || ( strcmp(pathname, "/dev/dsp") != 0 && @@ -159,7 +159,7 @@ $NetBSD: patch-aa,v 1.5 2009/01/19 14:19:00 jmcneill Exp $ strcmp(pathname, "/dev/adsp") != 0 && strcmp(pathname, "/dev/sndstat") != 0 && strcmp(pathname, "/dev/mixer") != 0 )) { -@@ -2586,6 +2630,8 @@ FILE* fopen(const char *filename, const +@@ -2592,6 +2636,8 @@ FILE* fopen(const char *filename, const if (!filename || !mode || ( strcmp(filename, "/dev/dsp") != 0 && @@ -168,7 +168,7 @@ $NetBSD: patch-aa,v 1.5 2009/01/19 14:19:00 jmcneill Exp $ strcmp(filename, "/dev/adsp") != 0 && strcmp(filename, "/dev/sndstat") != 0 && strcmp(filename, "/dev/mixer") != 0 )) { -@@ -2629,6 +2675,8 @@ FILE *fopen64(const char *filename, cons +@@ -2635,6 +2681,8 @@ FILE *fopen64(const char *filename, cons if (!filename || !mode || ( strcmp(filename, "/dev/dsp") != 0 && diff --git a/audio/pulseaudio/patches/patch-ab b/audio/pulseaudio/patches/patch-ab index 2ac17dbbf6f..02c1931fe61 100644 --- a/audio/pulseaudio/patches/patch-ab +++ b/audio/pulseaudio/patches/patch-ab @@ -1,23 +1,20 @@ -$NetBSD: patch-ab,v 1.2 2009/07/28 12:52:40 tnn Exp $ +$NetBSD: patch-ab,v 1.3 2010/02/01 15:00:20 jmcneill Exp $ ---- src/daemon/main.c.orig 2009-01-13 00:11:38.000000000 +0100 +--- src/daemon/main.c.orig 2010-02-01 14:15:00.000000000 +0000 +++ src/daemon/main.c -@@ -302,7 +302,9 @@ static void set_all_rlimits(const pa_dae - #ifdef RLIMIT_MEMLOCK - set_one_rlimit(&conf->rlimit_memlock, RLIMIT_MEMLOCK, "RLIMIT_MEMLOCK"); - #endif -+#ifdef RLIMIT_AS - set_one_rlimit(&conf->rlimit_as, RLIMIT_AS, "RLIMIT_AS"); +@@ -640,6 +640,7 @@ int main(int argc, char *argv[]) { + * first take the autospawn lock to make things + * synchronous. */ + ++#if notyet /* XXX broken on NetBSD and FreeBSD */ + if ((autospawn_fd = pa_autospawn_lock_init()) < 0) { + pa_log("Failed to initialize autospawn lock"); + goto finish; +@@ -651,6 +652,7 @@ int main(int argc, char *argv[]) { + } + + autospawn_locked = TRUE; +#endif - #ifdef RLIMIT_LOCKS - set_one_rlimit(&conf->rlimit_locks, RLIMIT_LOCKS, "RLIMIT_LOCKS"); - #endif -@@ -351,7 +353,7 @@ int main(int argc, char *argv[]) { - pa_log_set_maximal_level(PA_LOG_INFO); - pa_log_set_ident("pulseaudio"); + } --#if defined(__linux__) && defined(__OPTIMIZE__) -+#if defined(__linux__) && defined(__OPTIMIZE__) && 0 /* CVE-2009-1894 */ - /* - Disable lazy relocations to make usage of external libraries - more deterministic for our RT threads. We abuse __OPTIMIZE__ as + if (conf->daemonize) { diff --git a/audio/pulseaudio/patches/patch-ac b/audio/pulseaudio/patches/patch-ac index b380c744324..4635529571d 100644 --- a/audio/pulseaudio/patches/patch-ac +++ b/audio/pulseaudio/patches/patch-ac @@ -1,39 +1,13 @@ -$NetBSD: patch-ac,v 1.3 2008/12/24 04:11:17 dsainty Exp $ +$NetBSD: patch-ac,v 1.4 2010/02/01 15:00:20 jmcneill Exp $ ---- src/tests/rtstutter.c.orig 2008-08-19 17:25:05.000000000 -0400 -+++ src/tests/rtstutter.c 2008-12-23 13:25:08.000000000 -0500 -@@ -42,6 +42,7 @@ static int msec_lower, msec_upper; - static void* work(void *p) PA_GCC_NORETURN; +--- src/daemon/start-pulseaudio-x11.in.orig 2010-02-01 14:16:08.000000000 +0000 ++++ src/daemon/start-pulseaudio-x11.in +@@ -21,7 +21,7 @@ set -e - static void* work(void *p) { -+#if 0 - cpu_set_t mask; - struct sched_param param; + [ -z "$PULSE_SERVER" ] -@@ -83,10 +84,11 @@ static void* work(void *p) { - } while (now.tv_sec < end.tv_sec || - (now.tv_sec == end.tv_sec && now.tv_nsec < end.tv_nsec)); - } -+#endif - } +-@PA_BINARY@ --start "$@" ++@PA_BINARY@ -D "$@" - int main(int argc, char*argv[]) { -- int n; -+ int n, ncpus; + if [ x"$DISPLAY" != x ] ; then - srand((unsigned) time(NULL)); - -@@ -106,7 +108,12 @@ int main(int argc, char*argv[]) { - - pa_log_notice("Creating random latencies in the range of %ims to %ims.", msec_lower, msec_upper); - -- for (n = 1; n < sysconf(_SC_NPROCESSORS_CONF); n++) { -+#ifdef _SC_NPROCESSORS_CONF -+ ncpus = sysconf(_SC_NPROCESSORS_CONF); -+#else -+ ncpus = 1; -+#endif -+ for (n = 1; n < ncpus; n++) { - pthread_t t; - pa_assert_se(pthread_create(&t, NULL, work, PA_INT_TO_PTR(n)) == 0); - } diff --git a/audio/pulseaudio/patches/patch-ad b/audio/pulseaudio/patches/patch-ad index 1bc53aa8bf5..a295331c9ab 100644 --- a/audio/pulseaudio/patches/patch-ad +++ b/audio/pulseaudio/patches/patch-ad @@ -1,8 +1,8 @@ -$NetBSD: patch-ad,v 1.3 2008/12/25 21:53:30 ahoka Exp $ +$NetBSD: patch-ad,v 1.4 2010/02/01 15:00:20 jmcneill Exp $ ---- src/Makefile.am.orig 2008-12-20 11:45:28.000000000 -0500 -+++ src/Makefile.am 2008-12-20 11:47:47.000000000 -0500 -@@ -26,9 +26,9 @@ +--- src/Makefile.am.orig 2009-11-23 03:57:04.000000000 +0000 ++++ src/Makefile.am +@@ -26,13 +26,13 @@ pulseincludedir=$(includedir)/pulse pulsecoreincludedir=$(includedir)/pulsecore @@ -11,10 +11,15 @@ $NetBSD: patch-ad,v 1.3 2008/12/25 21:53:30 ahoka Exp $ pulselibexecdir=$(libexecdir)/pulse -xdgautostartdir=$(sysconfdir)/xdg/autostart +xdgautostartdir=$(PREFIX)/share/gnome/autostart + alsaprofilesetsdir=$(datadir)/pulseaudio/alsa-mixer/profile-sets + alsapathsdir=$(datadir)/pulseaudio/alsa-mixer/paths + udevrulesdir=/lib/udev/rules.d +-dbuspolicydir=$(sysconfdir)/dbus-1/system.d ++dbuspolicydir=$(EGDIR) ################################### # Defines # -@@ -38,7 +38,7 @@ +@@ -42,7 +42,7 @@ PA_BINARY=$(bindir)/pulseaudio$(EXEEXT) if OS_IS_WIN32 PA_DEFAULT_CONFIG_DIR=%PULSE_ROOT% else @@ -23,12 +28,12 @@ $NetBSD: patch-ad,v 1.3 2008/12/25 21:53:30 ahoka Exp $ endif ################################### -@@ -1396,7 +1396,7 @@ +@@ -1419,7 +1419,7 @@ module_x11_cork_request_la_LIBADD = $(AM # OSS - liboss_util_la_SOURCES = modules/oss-util.c modules/oss-util.h + liboss_util_la_SOURCES = modules/oss/oss-util.c modules/oss/oss-util.h -liboss_util_la_LDFLAGS = -avoid-version +liboss_util_la_LDFLAGS = -avoid-version $(LIBOSSAUDIO) - liboss_util_la_LIBADD = libpulsecore.la + liboss_util_la_LIBADD = libpulsecore-@PA_MAJORMINORMICRO@.la libpulsecommon-@PA_MAJORMINORMICRO@.la libpulse.la - module_oss_la_SOURCES = modules/module-oss.c + module_oss_la_SOURCES = modules/oss/module-oss.c diff --git a/audio/pulseaudio/patches/patch-ae b/audio/pulseaudio/patches/patch-ae index bc75140bc43..e326cb794e4 100644 --- a/audio/pulseaudio/patches/patch-ae +++ b/audio/pulseaudio/patches/patch-ae @@ -1,30 +1,13 @@ -$NetBSD: patch-ae,v 1.1.1.1 2008/12/18 14:42:56 jmcneill Exp $ +$NetBSD: patch-ae,v 1.2 2010/02/01 15:00:20 jmcneill Exp $ ---- src/pulsecore/socket-util.c.orig 2008-12-18 00:53:11.000000000 -0500 -+++ src/pulsecore/socket-util.c -@@ -202,9 +202,11 @@ void pa_make_udp_socket_low_delay(int fd - } +--- src/pulse/context.c.orig 2010-02-01 14:16:41.000000000 +0000 ++++ src/pulse/context.c +@@ -718,7 +718,7 @@ static int context_autospawn(pa_context - int pa_socket_set_rcvbuf(int fd, size_t l) { -+ int bufsz = (int)l; -+ - pa_assert(fd >= 0); + /* Setup argv */ + argv[n++] = c->conf->daemon_binary; +- argv[n++] = "--start"; ++ argv[n++] = "-D"; -- if (setsockopt(fd, SOL_SOCKET, SO_RCVBUF, (void*)&l, sizeof(l)) < 0) { -+ if (setsockopt(fd, SOL_SOCKET, SO_RCVBUF, (void*)&bufsz, sizeof(bufsz)) < 0) { - pa_log_warn("SO_RCVBUF: %s", pa_cstrerror(errno)); - return -1; - } -@@ -213,9 +215,11 @@ int pa_socket_set_rcvbuf(int fd, size_t - } - - int pa_socket_set_sndbuf(int fd, size_t l) { -+ int bufsz = (int)l; -+ - pa_assert(fd >= 0); - -- if (setsockopt(fd, SOL_SOCKET, SO_SNDBUF, (void*)&l, sizeof(l)) < 0) { -+ if (setsockopt(fd, SOL_SOCKET, SO_SNDBUF, (void*)&bufsz, sizeof(bufsz)) < 0) { - pa_log("SO_SNDBUF: %s", pa_cstrerror(errno)); - return -1; - } + while (n < PA_ELEMENTSOF(argv)-1) { + char *a; diff --git a/audio/pulseaudio/patches/patch-af b/audio/pulseaudio/patches/patch-af index 9de7b4ff145..1fff3b65097 100644 --- a/audio/pulseaudio/patches/patch-af +++ b/audio/pulseaudio/patches/patch-af @@ -1,13 +1,13 @@ -$NetBSD: patch-af,v 1.1.1.1 2008/12/18 14:42:56 jmcneill Exp $ +$NetBSD: patch-af,v 1.2 2010/02/01 15:00:20 jmcneill Exp $ ---- src/daemon/default.pa.in.orig 2008-12-18 08:30:19.000000000 -0500 -+++ src/daemon/default.pa.in -@@ -87,7 +87,7 @@ load-module module-rescue-streams - load-module module-always-sink +--- src/pulse/util.c.orig 2010-02-01 14:18:18.000000000 +0000 ++++ src/pulse/util.c +@@ -178,7 +178,7 @@ char *pa_get_binary_name(char *s, size_t + } + #endif - ### Automatically suspend sinks/sources that become idle for too long --load-module module-suspend-on-idle -+#load-module module-suspend-on-idle - - ### If autoexit on idle is enabled we want to make sure we only quit - ### when no local session needs us anymore. +-#ifdef __linux__ ++#if defined(__linux__) || defined(__NetBSD__) + { + char *rp; + /* This works on Linux only */ diff --git a/audio/pulseaudio/patches/patch-ag b/audio/pulseaudio/patches/patch-ag index 9c459bd5c30..0f017c4a677 100644 --- a/audio/pulseaudio/patches/patch-ag +++ b/audio/pulseaudio/patches/patch-ag @@ -1,16 +1,22 @@ -$NetBSD: patch-ag,v 1.1 2008/12/23 02:15:27 hasso Exp $ +$NetBSD: patch-ag,v 1.2 2010/02/01 15:00:20 jmcneill Exp $ ---- ./src/modules/oss-util.c.orig 2008-12-21 22:03:48 +0200 -+++ ./src/modules/oss-util.c 2008-12-21 22:04:31 +0200 -@@ -298,7 +298,11 @@ static int get_device_number(const char - int r; +--- src/pulsecore/shm.c.orig 2010-02-01 14:21:15.000000000 +0000 ++++ src/pulsecore/shm.c +@@ -91,7 +91,7 @@ struct shm_marker { + #define SHM_MARKER_SIZE PA_ALIGN(sizeof(struct shm_marker)) - if (!(p = rp = pa_readlink(dev))) { -+#ifdef ENOLINK - if (errno != EINVAL && errno != ENOLINK) { -+#else -+ if (errno != EINVAL) { -+#endif - r = -1; - goto finish; + static char *segment_name(char *fn, size_t l, unsigned id) { +- pa_snprintf(fn, l, "/pulse-shm-%u", id); ++ pa_snprintf(fn, l, "/tmp/pulse-shm-%u", id); + return fn; + } + +@@ -142,7 +142,7 @@ int pa_shm_create_rw(pa_shm *m, size_t s + pa_random(&m->id, sizeof(m->id)); + segment_name(fn, sizeof(fn), m->id); + +- if ((fd = shm_open(fn, O_RDWR|O_CREAT|O_EXCL, mode & 0444)) < 0) { ++ if ((fd = shm_open(fn, O_RDWR|O_CREAT|O_EXCL, mode & 0644)) < 0) { + pa_log("shm_open() failed: %s", pa_cstrerror(errno)); + goto fail; } diff --git a/audio/pulseaudio/patches/patch-ca b/audio/pulseaudio/patches/patch-ca index 486e43d966f..9847af808b4 100644 --- a/audio/pulseaudio/patches/patch-ca +++ b/audio/pulseaudio/patches/patch-ca @@ -1,6 +1,6 @@ -$NetBSD: patch-ca,v 1.1 2009/01/21 15:40:20 drochner Exp $ +$NetBSD: patch-ca,v 1.2 2010/02/01 15:00:20 jmcneill Exp $ ---- src/pulse/utf8.c.orig 2008-09-03 23:13:43.000000000 +0200 +--- src/pulse/utf8.c.orig 2009-09-10 00:04:58.000000000 +0000 +++ src/pulse/utf8.c @@ -55,6 +55,7 @@ @@ -10,7 +10,7 @@ $NetBSD: patch-ca,v 1.1 2009/01/21 15:40:20 drochner Exp $ #endif #include <pulse/xmalloc.h> -@@ -243,11 +244,11 @@ static char* iconv_simple(const char *st +@@ -238,11 +239,11 @@ static char* iconv_simple(const char *st } char* pa_utf8_to_locale (const char *str) { diff --git a/audio/pulseaudio/patches/patch-da b/audio/pulseaudio/patches/patch-da new file mode 100644 index 00000000000..1bfda54131c --- /dev/null +++ b/audio/pulseaudio/patches/patch-da @@ -0,0 +1,45 @@ +$NetBSD: patch-da,v 1.1 2010/02/01 15:00:20 jmcneill Exp $ + +--- src/modules/module-cli.c.orig 2009-11-23 03:57:05.000000000 +0000 ++++ src/modules/module-cli.c +@@ -105,6 +105,32 @@ int pa__init(pa_module*m) { + * of log messages, particularly because if stdout and stderr are + * dup'ed they share the same O_NDELAY, too. */ + ++#ifndef O_CLOEXEC ++ if ((fd = open("/dev/tty", O_RDWR|O_NONBLOCK)) >= 0) { ++ int flags; ++ if ((flags = fcntl(fd, F_GETFD)) < 0) { ++ pa_log_debug("Couldn't get file handle flags"); ++ close(fd); ++ fd = -1; ++ goto error; ++ } ++ flags |= FD_CLOEXEC; ++ if (fcntl(fd, F_SETFD, flags) < 0) { ++ pa_log_debug("Couldn't set file handle flags"); ++ close(fd); ++ fd = -1; ++ goto error; ++ } ++ io = pa_iochannel_new(m->core->mainloop, fd, fd); ++ pa_log_debug("Managed to open /dev/tty."); ++ } ++error: ++ if (fd < 0) { ++ io = pa_iochannel_new(m->core->mainloop, STDIN_FILENO, STDOUT_FILENO); ++ pa_iochannel_set_noclose(io, TRUE); ++ pa_log_debug("Failed to open /dev/tty, using stdin/stdout fds instead."); ++ } ++#else + if ((fd = open("/dev/tty", O_RDWR|O_CLOEXEC|O_NONBLOCK)) >= 0) { + io = pa_iochannel_new(m->core->mainloop, fd, fd); + pa_log_debug("Managed to open /dev/tty."); +@@ -113,6 +139,7 @@ int pa__init(pa_module*m) { + pa_iochannel_set_noclose(io, TRUE); + pa_log_debug("Failed to open /dev/tty, using stdin/stdout fds instead."); + } ++#endif + + m->userdata = pa_cli_new(m->core, io, m); + pa_cli_set_eof_callback(m->userdata, exit_on_eof ? eof_and_exit_cb : eof_and_unload_cb, m); diff --git a/audio/pulseaudio/patches/patch-db b/audio/pulseaudio/patches/patch-db new file mode 100644 index 00000000000..c65a60f672d --- /dev/null +++ b/audio/pulseaudio/patches/patch-db @@ -0,0 +1,15 @@ +$NetBSD: patch-db,v 1.1 2010/02/01 15:00:20 jmcneill Exp $ + +--- src/daemon/default.pa.in.orig 2009-11-23 03:57:05.000000000 +0000 ++++ src/daemon/default.pa.in +@@ -49,8 +49,8 @@ load-module module-augment-properties + #load-module module-pipe-sink + + ### Automatically load driver modules depending on the hardware available +-.ifexists module-udev-detect@PA_SOEXT@ +-load-module module-udev-detect ++.ifexists module-hal-detect@PA_SOEXT@ ++load-module module-hal-detect + .else + ### Alternatively use the static hardware detection module (for systems that + ### lack udev support) diff --git a/audio/pulseaudio/patches/patch-dc b/audio/pulseaudio/patches/patch-dc new file mode 100644 index 00000000000..a88cc3372a6 --- /dev/null +++ b/audio/pulseaudio/patches/patch-dc @@ -0,0 +1,16 @@ +$NetBSD: patch-dc,v 1.1 2010/02/01 15:00:20 jmcneill Exp $ + +--- src/modules/module-hal-detect.c.orig 2009-09-10 00:04:58.000000000 +0000 ++++ src/modules/module-hal-detect.c +@@ -337,6 +337,11 @@ static int hal_device_load_oss(struct us + + /* We store only one entry per card, hence we look for the originating device */ + originating_udi = libhal_device_get_property_string(u->context, udi, "oss.originating_device", &error); ++ if (dbus_error_is_set(&error) || !originating_udi) { ++ if (dbus_error_is_set(&error)) ++ dbus_error_free(&error); ++ originating_udi = libhal_device_get_property_string(u->context, udi, "sound.originating_device", &error); ++ } + if (dbus_error_is_set(&error) || !originating_udi) + goto fail; + |