summaryrefslogtreecommitdiff
path: root/time/emiclock/patches/patch-aa
blob: af715b8beba1dbb57631a9b3dc450f0c0877e9a8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
$NetBSD: patch-aa,v 1.1.1.1 2000/12/17 23:32:17 wiz Exp $

--- include/sound.h.orig	Sat Jan 11 12:12:55 1997
+++ include/sound.h	Sun May 23 10:48:03 1999
@@ -237,6 +237,42 @@
 
 #endif	/* FreeBSD */
 
+/*
+ *  NetBSD
+ */
+
+#if defined(__NetBSD__) && defined(USE_SOUND)
+
+/* NetBSD with MB6258V */
+
+#include <errno.h>
+#include <unistd.h>
+#include <sys/ioctl.h>
+#include <sys/types.h>
+#include <sys/file.h>
+#include <sys/stat.h>
+#include <sys/audioio.h>
+#include <machine/bswap.h>
+
+#define	AUDIO_DEVICE		"/dev/audio"
+#define	AUDIO_CTLDEVICE		"/dev/audioctl"
+#define	AUDIOMAGICNUMBER	(0x2e736e64)		/* ".snd" */
+#ifndef AUDIO_ENCODING_LINEAR
+#define AUDIO_ENCODING_LINEAR	(3)	/* Linear PCM encoding */
+#endif
+
+#undef	O_RDWR
+#define	O_RDWR	O_WRONLY	/* audio $B%G%P%$%9$OF1;~%*!<%W%s$G$-$J$$!)(B */
+
+struct SoundCacheBufferTag {
+    char	*soundCacheBuffer;
+    int		soundLength;
+    audio_info_t	soundBParam;
+};
+
+#define	SoundCacheBuffer	struct SoundCacheBufferTag
+
+#endif	/* NetBSD */
 
 #else	/* USE_NETAUDIO */