diff options
author | wiz <wiz@pkgsrc.org> | 2007-06-08 17:18:53 +0000 |
---|---|---|
committer | wiz <wiz@pkgsrc.org> | 2007-06-08 17:18:53 +0000 |
commit | d045aecd08ee87ef828ea08658c3c5e2622fe87f (patch) | |
tree | f13ae535dfe1e64f43460206b32445e12cc8b245 /audio/timidity | |
parent | f560ed23e35a51ea15325d8eaa15a9e7f5f0d5fc (diff) | |
download | pkgsrc-d045aecd08ee87ef828ea08658c3c5e2622fe87f.tar.gz |
Support PM_REQ_GETQSIZ and PM_REQ_GETFRAGSIZ in sun_a.c to improve
playback. From Sergey Svishchev in PR 35772.
Bump PKGREVISION.
Diffstat (limited to 'audio/timidity')
-rw-r--r-- | audio/timidity/Makefile | 4 | ||||
-rw-r--r-- | audio/timidity/distinfo | 4 | ||||
-rw-r--r-- | audio/timidity/patches/patch-aa | 59 |
3 files changed, 52 insertions, 15 deletions
diff --git a/audio/timidity/Makefile b/audio/timidity/Makefile index 0f4b0b2af60..afab29f0fff 100644 --- a/audio/timidity/Makefile +++ b/audio/timidity/Makefile @@ -1,8 +1,8 @@ -# $NetBSD: Makefile,v 1.60 2007/01/11 00:27:37 wiz Exp $ +# $NetBSD: Makefile,v 1.61 2007/06/08 17:18:53 wiz Exp $ DISTNAME= TiMidity++-2.13.2 PKGNAME= ${DISTNAME:S/TiMidity++/timidity/} -PKGREVISION= 6 +PKGREVISION= 7 CATEGORIES= audio MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=timidity/} EXTRACT_SUFX= .tar.bz2 diff --git a/audio/timidity/distinfo b/audio/timidity/distinfo index 7179f8ddc69..2b33da764b6 100644 --- a/audio/timidity/distinfo +++ b/audio/timidity/distinfo @@ -1,9 +1,9 @@ -$NetBSD: distinfo,v 1.12 2005/12/11 19:40:16 joerg Exp $ +$NetBSD: distinfo,v 1.13 2007/06/08 17:18:53 wiz Exp $ SHA1 (TiMidity++-2.13.2.tar.bz2) = 8e603146e1164335303a5ac5dff291f369241b4e RMD160 (TiMidity++-2.13.2.tar.bz2) = 0156221846a88abef9312700a050972d85084fd8 Size (TiMidity++-2.13.2.tar.bz2) = 1581230 bytes -SHA1 (patch-aa) = 3e006fe39bcc2644b7cea30ffce318091e1b8915 +SHA1 (patch-aa) = ccae42f9629b287da55f0b834557d154719f23d3 SHA1 (patch-ab) = 6c4938e1b31dc066354aebd364c848bb88b20eb4 SHA1 (patch-ac) = 56e738ef60dc8040d27bb50722ed5e0294d343e4 SHA1 (patch-ae) = 3f55ea58e91bd97ff42fbe67e8c89514c29aa2e9 diff --git a/audio/timidity/patches/patch-aa b/audio/timidity/patches/patch-aa index 62b47231fa2..93c170e5491 100644 --- a/audio/timidity/patches/patch-aa +++ b/audio/timidity/patches/patch-aa @@ -1,16 +1,53 @@ -$NetBSD: patch-aa,v 1.6 2004/04/14 14:41:34 adam Exp $ +$NetBSD: patch-aa,v 1.7 2007/06/08 17:18:53 wiz Exp $ ---- timidity/sun_a.c.orig 2002-07-19 00:43:58.000000000 +0000 +--- timidity/sun_a.c.orig 2007-06-08 17:14:22.000000000 +0000 +++ timidity/sun_a.c -@@ -70,7 +70,11 @@ - #define SUNAUDIO_AENC_SIGWORD AENC_SIGWORDB - #endif +@@ -300,6 +300,18 @@ int output_data(char *buff, int32 nbytes -+#ifndef __NetBSD__ - #define AUDIO_DEV "/dev/audio" -+#else -+#define AUDIO_DEV "/dev/sound" -+#endif - #define AUDIO_CTLDEV "/dev/audioctl" + #if !defined(I_FLUSH) || !defined(FLUSHW) ++# if defined(AUDIO_FLUSH) /* NetBSD */ ++static int sun_discard_playing(void) ++{ ++ if(ioctl(dpm.fd, AUDIO_FLUSH, NULL) < 0) ++ { ++ ctl->cmsg(CMSG_ERROR, VERB_NORMAL, "%s: (ioctl) %s", ++ dpm.name, strerror(errno)); ++ return -1; ++ } ++ return 0; ++} ++# else + static void null_proc(){} + static int sun_discard_playing(void) + { +@@ -312,6 +324,7 @@ static int sun_discard_playing(void) + signal(SIGALRM, orig_alarm_handler); + return open_output(); + } ++# endif + #else + static int sun_discard_playing(void) + { +@@ -332,6 +345,21 @@ static int acntl(int request, void *arg) + switch(request) + { ++#ifdef __NetBSD__ ++ case PM_REQ_GETQSIZ: ++ if(ioctl(audioctl_fd, AUDIO_GETINFO, &auinfo) < 0) ++ return -1; ++ return auinfo.play.buffer_size; ++ ++ case PM_REQ_GETFRAGSIZ: ++ if(ioctl(audioctl_fd, AUDIO_GETINFO, &auinfo) < 0) ++ return -1; ++ return auinfo.blocksize; ++ ++ case PM_REQ_OUTPUT_FINISH: ++ return ioctl(audioctl_fd, AUDIO_DRAIN, NULL); ++#endif ++ + case PM_REQ_GETFILLED: + if(ioctl(audioctl_fd, AUDIO_GETINFO, &auinfo) < 0) + return -1; |