diff options
author | hasso <hasso@pkgsrc.org> | 2008-12-23 02:15:27 +0000 |
---|---|---|
committer | hasso <hasso@pkgsrc.org> | 2008-12-23 02:15:27 +0000 |
commit | a4d0917d35748b5245a50f1d05a87e062f4afd35 (patch) | |
tree | 6d5a4d484f1cb3914863773d11c8972456c45040 /audio | |
parent | 0df3b92042aa58d86e5bf379a37cdb664bbea0d5 (diff) | |
download | pkgsrc-a4d0917d35748b5245a50f1d05a87e062f4afd35.tar.gz |
Portability fixes to make it compile in DragonFly and possibly to help
other platforms.
Diffstat (limited to 'audio')
-rw-r--r-- | audio/pulseaudio/distinfo | 8 | ||||
-rw-r--r-- | audio/pulseaudio/patches/patch-ag | 16 | ||||
-rw-r--r-- | audio/pulseaudio/patches/patch-ah | 85 | ||||
-rw-r--r-- | audio/pulseaudio/patches/patch-ai | 15 | ||||
-rw-r--r-- | audio/pulseaudio/patches/patch-aj | 15 | ||||
-rw-r--r-- | audio/pulseaudio/patches/patch-ba | 26 |
6 files changed, 160 insertions, 5 deletions
diff --git a/audio/pulseaudio/distinfo b/audio/pulseaudio/distinfo index d0d404ddd51..ead567ee239 100644 --- a/audio/pulseaudio/distinfo +++ b/audio/pulseaudio/distinfo @@ -1,4 +1,4 @@ -$NetBSD: distinfo,v 1.5 2008/12/20 17:53:51 jmcneill Exp $ +$NetBSD: distinfo,v 1.6 2008/12/23 02:15:27 hasso Exp $ SHA1 (pulseaudio-0.9.13.tar.gz) = c8482f1bb42d5213bfdbe2154e1a55b7bc04c915 RMD160 (pulseaudio-0.9.13.tar.gz) = 07cea9939dfb4fc76f13bf01dfe22ab6d0fd8459 @@ -9,5 +9,9 @@ SHA1 (patch-ac) = 8f61cf7c4a6681ab53c9ddf1007acb1bf524fe15 SHA1 (patch-ad) = 40474c4e04dffe836c41ff348d959c821da527fd SHA1 (patch-ae) = 1cd31d18c133fdd5e8db59be319ba5b7a45fe0fe SHA1 (patch-af) = 31b8564cb91aabb5de5490659e77de984fd1920b -SHA1 (patch-ba) = 518d23027fc9467a8bae2385233c2991136ee905 +SHA1 (patch-ag) = 67e3330c52c605e1eec505166e4ceed1a1277b11 +SHA1 (patch-ah) = 13cee1dc10be17f51978208843048ba9db7d9a3f +SHA1 (patch-ai) = b8e9e2dee9d1c5d9de488cfa0d06440eedacb7c6 +SHA1 (patch-aj) = 50edf909d5d7cc35e925685cdf0831e73d06f6ec +SHA1 (patch-ba) = b3e587cad73564c47ec921cf1c916d89102d36db SHA1 (patch-bb) = ded51f4642163dd5f78bb51522df64cb6ef8b985 diff --git a/audio/pulseaudio/patches/patch-ag b/audio/pulseaudio/patches/patch-ag new file mode 100644 index 00000000000..9c459bd5c30 --- /dev/null +++ b/audio/pulseaudio/patches/patch-ag @@ -0,0 +1,16 @@ +$NetBSD: patch-ag,v 1.1 2008/12/23 02:15:27 hasso 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; + + if (!(p = rp = pa_readlink(dev))) { ++#ifdef ENOLINK + if (errno != EINVAL && errno != ENOLINK) { ++#else ++ if (errno != EINVAL) { ++#endif + r = -1; + goto finish; + } diff --git a/audio/pulseaudio/patches/patch-ah b/audio/pulseaudio/patches/patch-ah new file mode 100644 index 00000000000..b2eda322c7e --- /dev/null +++ b/audio/pulseaudio/patches/patch-ah @@ -0,0 +1,85 @@ +$NetBSD: patch-ah,v 1.1 2008/12/23 02:15:27 hasso Exp $ + +--- src/pulsecore/core-util.c.orig 2008-12-21 23:55:12 +0200 ++++ src/pulsecore/core-util.c 2008-12-22 00:26:22 +0200 +@@ -1026,12 +1026,21 @@ int pa_uid_in_group(uid_t uid, const cha + char **i; + int r = -1; + ++#ifdef _SC_GETGR_R_SIZE_MAX + g_n = sysconf(_SC_GETGR_R_SIZE_MAX); + g_buf = pa_xmalloc((size_t) g_n); ++#else ++ g_buf = pa_xmalloc(512); ++#endif + ++#ifdef _SC_GETPW_R_SIZE_MAX + p_n = sysconf(_SC_GETPW_R_SIZE_MAX); + p_buf = pa_xmalloc((size_t) p_n); ++#else ++ p_buf = pa_xmalloc(512); ++#endif + ++#ifdef HAVE_GETGRNAM_R + errno = 0; + if (getgrnam_r(name, &grbuf, g_buf, (size_t) g_n, &gr) != 0 || !gr) { + +@@ -1040,14 +1049,28 @@ int pa_uid_in_group(uid_t uid, const cha + + goto finish; + } ++#else ++ gr = getgrnam(name); ++ ++ if (gr == NULL) { ++ errno = ENOENT; ++ goto finish; ++ } ++#endif + + r = 0; + for (i = gr->gr_mem; *i; i++) { + struct passwd pwbuf, *pw; + ++#ifdef HAVE_GETPWNAM_R + errno = 0; + if (getpwnam_r(*i, &pwbuf, p_buf, (size_t) p_n, &pw) != 0 || !pw) + continue; ++#else ++ pw = getpwnam(*i); ++ if (pw == NULL) ++ continue; ++#endif + + if (pw->pw_uid == uid) { + r = 1; +@@ -1069,9 +1092,14 @@ gid_t pa_get_gid_of_group(const char *na + long g_n; + struct group grbuf, *gr; + ++#ifdef _SC_GETGR_R_SIZE_MAX + g_n = sysconf(_SC_GETGR_R_SIZE_MAX); + g_buf = pa_xmalloc((size_t) g_n); ++#else ++ g_buf = pa_xmalloc(512); ++#endif + ++#ifdef HAVE_GETGRNAM_R + errno = 0; + if (getgrnam_r(name, &grbuf, g_buf, (size_t) g_n, &gr) != 0 || !gr) { + +@@ -1080,6 +1108,14 @@ gid_t pa_get_gid_of_group(const char *na + + goto finish; + } ++#else ++ gr = getgrnam(name); ++ ++ if (gr == NULL) { ++ errno = ENOENT; ++ goto finish; ++ } ++#endif + + ret = gr->gr_gid; + diff --git a/audio/pulseaudio/patches/patch-ai b/audio/pulseaudio/patches/patch-ai new file mode 100644 index 00000000000..63c879ac332 --- /dev/null +++ b/audio/pulseaudio/patches/patch-ai @@ -0,0 +1,15 @@ +$NetBSD: patch-ai,v 1.1 2008/12/23 02:15:27 hasso Exp $ + +--- src/modules/rtp/rtp.c.orig 2008-12-22 00:50:26 +0200 ++++ src/modules/rtp/rtp.c 2008-12-22 00:51:41 +0200 +@@ -35,6 +35,10 @@ + #include <sys/filio.h> + #endif + ++#ifdef HAVE_SYS_UIO_H ++#include <sys/uio.h> ++#endif ++ + #include <pulsecore/core-error.h> + #include <pulsecore/log.h> + #include <pulsecore/macro.h> diff --git a/audio/pulseaudio/patches/patch-aj b/audio/pulseaudio/patches/patch-aj new file mode 100644 index 00000000000..64b53ed4b77 --- /dev/null +++ b/audio/pulseaudio/patches/patch-aj @@ -0,0 +1,15 @@ +$NetBSD: patch-aj,v 1.1 2008/12/23 02:15:27 hasso Exp $ + +--- src/modules/rtp/sap.c.orig 2008-12-22 00:52:17 +0200 ++++ src/modules/rtp/sap.c 2008-12-22 00:52:43 +0200 +@@ -38,6 +38,10 @@ + #include <sys/filio.h> + #endif + ++#ifdef HAVE_SYS_UIO_H ++#include <sys/uio.h> ++#endif ++ + #include <pulse/xmalloc.h> + + #include <pulsecore/core-error.h> diff --git a/audio/pulseaudio/patches/patch-ba b/audio/pulseaudio/patches/patch-ba index 3fa22358ce5..af6d4a1813e 100644 --- a/audio/pulseaudio/patches/patch-ba +++ b/audio/pulseaudio/patches/patch-ba @@ -1,7 +1,7 @@ -$NetBSD: patch-ba,v 1.1 2008/12/20 16:10:25 ahoka Exp $ +$NetBSD: patch-ba,v 1.2 2008/12/23 02:15:27 hasso Exp $ ---- configure.ac.orig 2008-10-06 02:39:37.000000000 +0200 -+++ configure.ac +--- configure.ac.orig 2008-10-06 03:39:37 +0300 ++++ configure.ac 2008-12-23 03:11:41 +0200 @@ -125,6 +125,16 @@ AC_ARG_ENABLE([atomic-arm-memory-barrier no) ;; *) AC_MSG_ERROR(bad value ${enableval} for --disable-atomic-arm-linux-helpers) ;; @@ -45,6 +45,15 @@ $NetBSD: patch-ba,v 1.1 2008/12/20 16:10:25 ahoka Exp $ ;; esac fi +@@ -263,7 +283,7 @@ AC_HEADER_STDC + AC_CHECK_HEADERS([arpa/inet.h glob.h grp.h netdb.h netinet/in.h \ + netinet/in_systm.h netinet/tcp.h poll.h pwd.h sched.h \ + sys/mman.h sys/resource.h sys/select.h sys/socket.h sys/wait.h \ +- syslog.h sys/dl.h dlfcn.h linux/sockios.h]) ++ sys/uio.h syslog.h sys/dl.h dlfcn.h linux/sockios.h]) + AC_CHECK_HEADERS([netinet/ip.h], [], [], + [#include <sys/types.h> + #if HAVE_NETINET_IN_H @@ -292,6 +312,9 @@ AC_CHECK_HEADERS([sys/filio.h]) # Windows AC_CHECK_HEADERS([windows.h winsock2.h ws2tcpip.h]) @@ -55,3 +64,14 @@ $NetBSD: patch-ba,v 1.1 2008/12/20 16:10:25 ahoka Exp $ # Other AC_CHECK_HEADERS([sys/ioctl.h]) AC_CHECK_HEADERS([byteswap.h]) +@@ -359,8 +382,8 @@ AC_CHECK_FUNCS([lrintf strtof]) + AC_FUNC_FORK + AC_FUNC_GETGROUPS + AC_FUNC_SELECT_ARGTYPES +-AC_CHECK_FUNCS([chmod chown clock_gettime getaddrinfo getgrgid_r \ +- getpwuid_r gettimeofday getuid inet_ntop inet_pton mlock nanosleep \ ++AC_CHECK_FUNCS([chmod chown clock_gettime getaddrinfo getgrgid_r getgrnam_r \ ++ getpwnam_r getpwuid_r gettimeofday getuid inet_ntop inet_pton mlock nanosleep \ + pipe posix_fadvise posix_madvise posix_memalign setpgid setsid shm_open \ + sigaction sleep sysconf]) + AC_CHECK_FUNCS([mkfifo], [HAVE_MKFIFO=1], [HAVE_MKFIFO=0]) |