summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDiego Elio Pettenò <flameeyes@gentoo.org>2006-07-16 20:42:19 +0000
committerDiego Elio Pettenò <flameeyes@gentoo.org>2006-07-16 20:42:19 +0000
commitafda735235660ce6a63e3913111c003eeb3821a3 (patch)
treef546be24c6a266e0a9440b967fdedd4103f4c865 /media-sound/pulseaudio
parentVersion bump. (diff)
downloadhistorical-afda735235660ce6a63e3913111c003eeb3821a3.tar.gz
historical-afda735235660ce6a63e3913111c003eeb3821a3.tar.bz2
historical-afda735235660ce6a63e3913111c003eeb3821a3.zip
Add patch to build on FreeBSD, change init script so that it doesn't daemonise and properly fails when initialisation fails.
Package-Manager: portage-2.1.1_pre3
Diffstat (limited to 'media-sound/pulseaudio')
-rw-r--r--media-sound/pulseaudio/ChangeLog8
-rw-r--r--media-sound/pulseaudio/Manifest42
-rw-r--r--media-sound/pulseaudio/files/pulseaudio-0.9.2-fbsd.patch255
-rw-r--r--media-sound/pulseaudio/files/pulseaudio.conf.d8
-rw-r--r--media-sound/pulseaudio/files/pulseaudio.init.d3
-rw-r--r--media-sound/pulseaudio/pulseaudio-0.9.2.ebuild7
6 files changed, 293 insertions, 30 deletions
diff --git a/media-sound/pulseaudio/ChangeLog b/media-sound/pulseaudio/ChangeLog
index 0433b0cb89a6..424d884dbe07 100644
--- a/media-sound/pulseaudio/ChangeLog
+++ b/media-sound/pulseaudio/ChangeLog
@@ -1,6 +1,12 @@
# 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.1 2006/07/11 04:27:55 flameeyes Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-sound/pulseaudio/ChangeLog,v 1.2 2006/07/16 20:42:19 flameeyes Exp $
+
+ 16 Jul 2006; Diego Pettenò <flameeyes@gentoo.org>
+ +files/pulseaudio-0.9.2-fbsd.patch, files/pulseaudio.conf.d,
+ files/pulseaudio.init.d, pulseaudio-0.9.2.ebuild:
+ Add patch to build on FreeBSD, change init script so that it doesn't
+ daemonise and properly fails when initialisation fails.
*pulseaudio-0.9.2 (11 Jul 2006)
diff --git a/media-sound/pulseaudio/Manifest b/media-sound/pulseaudio/Manifest
index 12251cb5ace4..eee52eb05691 100644
--- a/media-sound/pulseaudio/Manifest
+++ b/media-sound/pulseaudio/Manifest
@@ -1,23 +1,27 @@
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
-AUX pulseaudio.conf.d 262 RMD160 3643c93c08ee96d1f85f666306d5fe4289df189b SHA1 5b63534e184a57a44124ccba8bff3193674700d9 SHA256 e5329d8af0c9cbc93cec990bfc3f75bce768d167f8420b60ede453fc4d3176ce
-MD5 f212d26ad160fcc5888f126e8be15a9c files/pulseaudio.conf.d 262
-RMD160 3643c93c08ee96d1f85f666306d5fe4289df189b files/pulseaudio.conf.d 262
-SHA256 e5329d8af0c9cbc93cec990bfc3f75bce768d167f8420b60ede453fc4d3176ce files/pulseaudio.conf.d 262
-AUX pulseaudio.init.d 442 RMD160 ad300537b8e584e66403761fe25b4b1f1abedd3e SHA1 f592c6576eda17a822b2812c1fe955ff75bd7207 SHA256 5702b1a4459ca98060a8f01109ca3ba04d0b036e487f0e1e1fa59ca78c5e137e
-MD5 ebf1c947ad28a9b2ece0a3f3dc0aab56 files/pulseaudio.init.d 442
-RMD160 ad300537b8e584e66403761fe25b4b1f1abedd3e files/pulseaudio.init.d 442
-SHA256 5702b1a4459ca98060a8f01109ca3ba04d0b036e487f0e1e1fa59ca78c5e137e files/pulseaudio.init.d 442
+AUX pulseaudio-0.9.2-fbsd.patch 7547 RMD160 366a65f6dc8adcd74b47b4bf3e530e4fd22daa26 SHA1 cbad4245f47a89ceb74c8b80cc04624d59721d1d SHA256 6a25e3a7ab11719c464457d81084e39e46ba70ac980d54e2c20e88d3aaea1180
+MD5 09caa154e7cc66b4bf2e59db0129200f files/pulseaudio-0.9.2-fbsd.patch 7547
+RMD160 366a65f6dc8adcd74b47b4bf3e530e4fd22daa26 files/pulseaudio-0.9.2-fbsd.patch 7547
+SHA256 6a25e3a7ab11719c464457d81084e39e46ba70ac980d54e2c20e88d3aaea1180 files/pulseaudio-0.9.2-fbsd.patch 7547
+AUX pulseaudio.conf.d 135 RMD160 8a20fa6acf64ab75fbb384c02774328ecd3863dc SHA1 4429cc7d6bfea5bb3107b7f1c93a17ccf46531b9 SHA256 569b0bbcf45d51fb47c47949e3e41ad723139c6aea290672c3f19f178b5d6b15
+MD5 e08a71b990ad747d97cd5c4656efd57c files/pulseaudio.conf.d 135
+RMD160 8a20fa6acf64ab75fbb384c02774328ecd3863dc files/pulseaudio.conf.d 135
+SHA256 569b0bbcf45d51fb47c47949e3e41ad723139c6aea290672c3f19f178b5d6b15 files/pulseaudio.conf.d 135
+AUX pulseaudio.init.d 487 RMD160 23fb57a10ee0cfc742293ab5c306acc5e6db097d SHA1 b74e91964a8c53ed82e3d987398a885707f1dc56 SHA256 ff54fb35797594d70c76c721f9f1190a2e688a32f366067d4ba75b946b18e42e
+MD5 413bad09f6c6b77da9237553661ab793 files/pulseaudio.init.d 487
+RMD160 23fb57a10ee0cfc742293ab5c306acc5e6db097d files/pulseaudio.init.d 487
+SHA256 ff54fb35797594d70c76c721f9f1190a2e688a32f366067d4ba75b946b18e42e files/pulseaudio.init.d 487
DIST pulseaudio-0.9.2.tar.gz 1100971 RMD160 32005e876868a507963d6ced53722dd9dd52cc78 SHA1 726a54651656c7d2bcfc6e4d45c7e0839c0519ff SHA256 b0e39ffffa19e0745da6ef2be1df353c3466991c82a191d83bdf4421387a463a
-EBUILD pulseaudio-0.9.2.ebuild 2469 RMD160 333bc50a430124f291f21781b26a8e2ff8d949b0 SHA1 13b31bd4c38510457084d32a3a5c9a2815f862b9 SHA256 f7c27d034b1539ceb215c430cf4b8c5496682b4fab7bb7b6549218be7837243d
-MD5 cebfc2cc971d5f1d583af000ec07317b pulseaudio-0.9.2.ebuild 2469
-RMD160 333bc50a430124f291f21781b26a8e2ff8d949b0 pulseaudio-0.9.2.ebuild 2469
-SHA256 f7c27d034b1539ceb215c430cf4b8c5496682b4fab7bb7b6549218be7837243d pulseaudio-0.9.2.ebuild 2469
-MISC ChangeLog 536 RMD160 f225622308e43db613e6f3b8f7ff88ad3b10b5c9 SHA1 c7dd6b4106db3b43e3381c83383cc7b9bcdbcd31 SHA256 c426154ca3aac30aa00a4e1dd084f63e1ba004b9ca49b86492cd8eb556c9ebb7
-MD5 649ed045abcd40d269806f8a0b5c352b ChangeLog 536
-RMD160 f225622308e43db613e6f3b8f7ff88ad3b10b5c9 ChangeLog 536
-SHA256 c426154ca3aac30aa00a4e1dd084f63e1ba004b9ca49b86492cd8eb556c9ebb7 ChangeLog 536
+EBUILD pulseaudio-0.9.2.ebuild 2531 RMD160 2f43d6f8af6265ae68fa773b5783fb6b7dcc224f SHA1 83bcd538eccda6375680bec4fee2592972edc946 SHA256 61dcea70d03f7065ae2713f7416856370e53bea791f4e68fcc52466ae5dc5e3f
+MD5 bcf6a710ceae711f0f8b6c535a75cb50 pulseaudio-0.9.2.ebuild 2531
+RMD160 2f43d6f8af6265ae68fa773b5783fb6b7dcc224f pulseaudio-0.9.2.ebuild 2531
+SHA256 61dcea70d03f7065ae2713f7416856370e53bea791f4e68fcc52466ae5dc5e3f pulseaudio-0.9.2.ebuild 2531
+MISC ChangeLog 834 RMD160 a6e59fb13a23239be213432306fba7cac4b57e8f SHA1 5407c6195eb3f733d9b7457867eb5f6a9b692597 SHA256 81337798a23cb8c115c39a817f2a418b47f5be236044ab2ce0c63fbaa3c484ab
+MD5 1760cacef7914d556e80b0d17e10f23d ChangeLog 834
+RMD160 a6e59fb13a23239be213432306fba7cac4b57e8f ChangeLog 834
+SHA256 81337798a23cb8c115c39a817f2a418b47f5be236044ab2ce0c63fbaa3c484ab ChangeLog 834
MISC metadata.xml 158 RMD160 6842e2189a50bd8a98e84802c38180ac1421c00e SHA1 703cea5a2109d41f7c87993c1f01d418a4c85174 SHA256 dfb5b47e6836db39fb187301dfcff1c2605e91d13d21db160806a563d8c75f9b
MD5 a1eaeb2ae801daeb712c90c060e922dc metadata.xml 158
RMD160 6842e2189a50bd8a98e84802c38180ac1421c00e metadata.xml 158
@@ -28,7 +32,7 @@ SHA256 1b50b0a6de74d80653dd9c4ef669d42e2ffb109e12b3e125a7e9b7f6573aee9b files/di
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.4 (GNU/Linux)
-iD8DBQFEsyjYAiZjviIA2XgRAvY9AKCH+0nNY1f51nSMws00oIa/hnnajACghpi/
-WL087XoStACtARlbOryLPWE=
-=sgxL
+iD8DBQFEuqTFAiZjviIA2XgRAqdwAJ9aSz63Tk7MUNWBMFywyiIuepaBZQCeL/Yi
+UNRuy9+z/MzwvYHk27Pvfq0=
+=5T19
-----END PGP SIGNATURE-----
diff --git a/media-sound/pulseaudio/files/pulseaudio-0.9.2-fbsd.patch b/media-sound/pulseaudio/files/pulseaudio-0.9.2-fbsd.patch
new file mode 100644
index 000000000000..729bd75b82b5
--- /dev/null
+++ b/media-sound/pulseaudio/files/pulseaudio-0.9.2-fbsd.patch
@@ -0,0 +1,255 @@
+Index: pulseaudio-0.9.2/configure.ac
+===================================================================
+--- pulseaudio-0.9.2.orig/configure.ac
++++ pulseaudio-0.9.2/configure.ac
+@@ -247,6 +247,9 @@ ACX_PTHREAD
+
+ AC_SYS_LARGEFILE
+
++# Check for open64 to know if the current system does have open64() and similar functions
++AC_CHECK_FUNCS([open64])
++
+ #### [lib]iconv ####
+
+ AM_ICONV
+Index: pulseaudio-0.9.2/src/utils/padsp.c
+===================================================================
+--- pulseaudio-0.9.2.orig/src/utils/padsp.c
++++ pulseaudio-0.9.2/src/utils/padsp.c
+@@ -36,6 +36,7 @@
+ #include <pthread.h>
+ #include <unistd.h>
+ #include <sys/socket.h>
++#include <sys/stat.h>
+ #include <dlfcn.h>
+ #include <errno.h>
+ #include <fcntl.h>
+@@ -44,7 +45,9 @@
+ #include <stdio.h>
+ #include <signal.h>
+
++#ifdef __linux__
+ #include <linux/sockios.h>
++#endif
+
+ #include <pulse/pulseaudio.h>
+ #include <pulsecore/llist.h>
+@@ -101,8 +104,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;
++#ifdef HAVE_OPEN64
+ static int (*_open64)(const char *, int, mode_t) = NULL;
+ static FILE* (*_fopen64)(const char *path, const char *mode) = NULL;
++#endif
+ static int (*_fclose)(FILE *f) = NULL;
+ static int (*_access)(const char *, int) = NULL;
+
+@@ -1302,7 +1307,11 @@ static int sndstat_open(int flags, int *
+
+ debug(DEBUG_LEVEL_NORMAL, __FILE__": sndstat_open()\n");
+
+- if (flags != O_RDONLY && flags != (O_RDONLY|O_LARGEFILE)) {
++ if (flags != O_RDONLY
++#ifdef O_LARGEFILE
++ && flags != (O_RDONLY|O_LARGEFILE)
++#endif
++ ) {
+ *_errno = EACCES;
+ debug(DEBUG_LEVEL_NORMAL, __FILE__": bad access!\n");
+ goto fail;
+@@ -1349,8 +1358,12 @@ int open(const char *filename, int flags
+ debug(DEBUG_LEVEL_VERBOSE, __FILE__": open(%s)\n", filename);
+
+ va_start(args, flags);
+- if (flags & O_CREAT)
++ if (flags & O_CREAT) {
++ if (sizeof(mode_t) < sizeof(int))
++ mode = va_arg(args, int);
++ else
+ mode = va_arg(args, mode_t);
++ }
+ va_end(args);
+
+ if (!function_enter()) {
+@@ -1587,6 +1600,7 @@ static int map_format_back(pa_sample_for
+ }
+
+ static int dsp_flush_fd(int fd) {
++#ifdef SIOCINQ
+ int l;
+
+ if (ioctl(fd, SIOCINQ, &l) < 0) {
+@@ -1605,6 +1619,10 @@ static int dsp_flush_fd(int fd) {
+ }
+
+ return 0;
++#else
++# warning "Your platform does not support SIOCINQ, something might not work as intended."
++ return 0;
++#endif
+ }
+
+ static int dsp_flush_socket(fd_info *i) {
+@@ -1629,6 +1647,7 @@ static int dsp_flush_socket(fd_info *i)
+ }
+
+ static int dsp_empty_socket(fd_info *i) {
++#ifdef SIOCINQ
+ int ret = -1;
+
+ /* Empty the socket */
+@@ -1652,6 +1671,10 @@ static int dsp_empty_socket(fd_info *i)
+ }
+
+ return ret;
++#else
++# warning "Your platform does not support SIOCINQ, something might not work as intended."
++ return 0;
++#endif
+ }
+
+ static int dsp_drain(fd_info *i) {
+@@ -1864,7 +1887,11 @@ static int dsp_ioctl(fd_info *i, unsigne
+ case SNDCTL_DSP_GETCAPS:
+ debug(DEBUG_LEVEL_NORMAL, __FILE__": SNDCTL_DSP_CAPS\n");
+
+- *(int*) argp = DSP_CAP_DUPLEX | DSP_CAP_MULTI;
++ *(int*) argp = DSP_CAP_DUPLEX
++#ifdef DSP_CAP_MULTI
++ | DSP_CAP_MULTI
++#endif
++ ;
+ break;
+
+ case SNDCTL_DSP_GETODELAY: {
+@@ -1895,11 +1922,15 @@ static int dsp_ioctl(fd_info *i, unsigne
+ }
+
+ exit_loop:
+-
++
++#ifdef SIOCINQ
+ if (ioctl(i->thread_fd, SIOCINQ, &l) < 0)
+ debug(DEBUG_LEVEL_NORMAL, __FILE__": SIOCINQ failed: %s\n", strerror(errno));
+ else
+ *(int*) argp += l;
++#else
++# warning "Your platform does not support SIOCINQ, something might not work as intended."
++#endif
+
+ pa_threaded_mainloop_unlock(i->mainloop);
+
+@@ -1946,7 +1977,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;
+- int l;
++ int l = 0;
+ size_t k = 0;
+
+ if (request == SNDCTL_DSP_GETOSPACE)
+@@ -1965,10 +1996,14 @@ static int dsp_ioctl(fd_info *i, unsigne
+ } else
+ k = i->fragment_size * i->n_fragments;
+
++#ifdef SIOCINQ
+ if (ioctl(i->thread_fd, SIOCINQ, &l) < 0) {
+ debug(DEBUG_LEVEL_NORMAL, __FILE__": SIOCINQ failed: %s\n", strerror(errno));
+ l = 0;
+ }
++#else
++# warning "Your platform does not dsp_flush_fd, something might not work as intended."
++#endif
+
+ bi->bytes = k > (size_t) l ? k - l : 0;
+ } else {
+@@ -1978,11 +2013,14 @@ static int dsp_ioctl(fd_info *i, unsigne
+ } else
+ k = 0;
+
++#ifdef SIOCINQ
+ if (ioctl(i->app_fd, SIOCINQ, &l) < 0) {
+ debug(DEBUG_LEVEL_NORMAL, __FILE__": SIOCINQ failed: %s\n", strerror(errno));
+ l = 0;
+ }
+-
++#else
++# warning "Your platform does not dsp_flush_fd, something might not work as intended."
++#endif
+ bi->bytes = k + l;
+ }
+
+@@ -2104,6 +2142,8 @@ int access(const char *pathname, int mod
+ return 0;
+ }
+
++#ifdef HAVE_OPEN64
++
+ 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
+ return open(filename, flags, mode);
+ }
+
++#endif
++
+ FILE* fopen(const char *filename, const char *mode) {
+ FILE *f = NULL;
+ int fd;
+@@ -2168,6 +2210,8 @@ FILE* fopen(const char *filename, const
+ return f;
+ }
+
++#ifdef HAVE_OPEN64
++
+ 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
+ return fopen(filename, mode);
+ }
+
++#endif
++
+ int fclose(FILE *f) {
+ fd_info *i;
+
+Index: pulseaudio-0.9.2/src/modules/rtp/sap.c
+===================================================================
+--- pulseaudio-0.9.2.orig/src/modules/rtp/sap.c
++++ pulseaudio-0.9.2/src/modules/rtp/sap.c
+@@ -28,6 +28,7 @@
+ #include <stdlib.h>
+ #include <sys/types.h>
+ #include <sys/socket.h>
++#include <netinet/in.h>
+ #include <arpa/inet.h>
+ #include <errno.h>
+ #include <string.h>
+Index: pulseaudio-0.9.2/src/modules/rtp/sdp.c
+===================================================================
+--- pulseaudio-0.9.2.orig/src/modules/rtp/sdp.c
++++ pulseaudio-0.9.2/src/modules/rtp/sdp.c
+@@ -28,6 +28,7 @@
+ #include <stdlib.h>
+ #include <sys/types.h>
+ #include <sys/socket.h>
++#include <netinet/in.h>
+ #include <arpa/inet.h>
+ #include <string.h>
+
+Index: pulseaudio-0.9.2/src/modules/rtp/module-rtp-recv.c
+===================================================================
+--- pulseaudio-0.9.2.orig/src/modules/rtp/module-rtp-recv.c
++++ pulseaudio-0.9.2/src/modules/rtp/module-rtp-recv.c
+@@ -236,7 +236,7 @@ static int mcast_socket(const struct soc
+ struct ipv6_mreq mr6;
+ memset(&mr6, 0, sizeof(mr6));
+ mr6.ipv6mr_multiaddr = ((const struct sockaddr_in6*) sa)->sin6_addr;
+- r = setsockopt(fd, IPPROTO_IPV6, IPV6_ADD_MEMBERSHIP, &mr6, sizeof(mr6));
++ r = setsockopt(fd, IPPROTO_IPV6, IPV6_JOIN_GROUP, &mr6, sizeof(mr6));
+ }
+
+ if (r < 0) {
diff --git a/media-sound/pulseaudio/files/pulseaudio.conf.d b/media-sound/pulseaudio/files/pulseaudio.conf.d
index f6027f0bb91d..afb2ef7cd139 100644
--- a/media-sound/pulseaudio/files/pulseaudio.conf.d
+++ b/media-sound/pulseaudio/files/pulseaudio.conf.d
@@ -2,12 +2,6 @@
# For more see "pulseaudio -h".
-
# Startup options
-
-# Daemonize, fail if startup fails
-PULSEAUDIO_START="-D --fail=true --log-target=syslog"
-
-# Local only (useful for root-only soundcard access)
-#PULSEAUDIO_OPTIONS=""
+PULSEAUDIO_OPTIONS="--log-target=syslog"
diff --git a/media-sound/pulseaudio/files/pulseaudio.init.d b/media-sound/pulseaudio/files/pulseaudio.init.d
index 7380b8b2aa4b..63bc90f58df6 100644
--- a/media-sound/pulseaudio/files/pulseaudio.init.d
+++ b/media-sound/pulseaudio/files/pulseaudio.init.d
@@ -9,7 +9,8 @@ depend() {
start() {
ebegin "Starting pulseaudio"
- start-stop-daemon --start --quiet --background --exec /usr/bin/pulseaudio -- $PULSEAUDIO_START $PULSEAUDIO_OPTIONS
+ # -D0 -> don't daemonize, leave that to s-s-d
+ start-stop-daemon --start --quiet --background --exec /usr/bin/pulseaudio -- $PULSEAUDIO_OPTIONS --fail=true -D0
eend $?
}
diff --git a/media-sound/pulseaudio/pulseaudio-0.9.2.ebuild b/media-sound/pulseaudio/pulseaudio-0.9.2.ebuild
index 2e9ae8e8989b..f2afa8a4f7ac 100644
--- a/media-sound/pulseaudio/pulseaudio-0.9.2.ebuild
+++ b/media-sound/pulseaudio/pulseaudio-0.9.2.ebuild
@@ -1,8 +1,8 @@
# Copyright 1999-2006 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/media-sound/pulseaudio/pulseaudio-0.9.2.ebuild,v 1.1 2006/07/11 04:27:55 flameeyes Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-sound/pulseaudio/pulseaudio-0.9.2.ebuild,v 1.2 2006/07/16 20:42:19 flameeyes Exp $
-inherit eutils libtool
+inherit eutils libtool autotools
DESCRIPTION="A networked sound server with an advanced plugin system"
HOMEPAGE="http://0pointer.de/lennart/projects/pulseaudio/"
@@ -45,6 +45,9 @@ src_unpack() {
unpack ${A}
cd "${S}"
+ epatch "${FILESDIR}/${P}-fbsd.patch"
+
+ eautoreconf
elibtoolize
}