pkgsrc/audio/splay/patches/patch-ab
dmcmahill 63b8d73d86 - mark as broken on big endian machines.
- add some patches that move in the direction of support for big endian
  machines.
2000-02-20 18:30:39 +00:00

37 lines
917 B
Text

$NetBSD: patch-ab,v 1.4 2000/02/20 18:30:39 dmcmahill Exp $
--- mpegsound/mpegsound.h.orig Fri Mar 6 12:43:55 1998
+++ mpegsound/mpegsound.h Sun Feb 20 13:02:24 2000
@@ -12,4 +12,5 @@
#include <stdio.h>
#include <sys/types.h>
+#include <machine/endian.h>
#ifdef PTHREADEDMPEG
@@ -91,4 +92,6 @@
/* Define values for Microsoft WAVE format */
/*******************************************/
+#if defined(BYTE_ORDER) && (BYTE_ORDER == LITTLE_ENDIAN )
+
#define RIFF 0x46464952
#define WAVE 0x45564157
@@ -101,4 +104,19 @@
#define MODE_MONO 0
#define MODE_STEREO 1
+
+#else
+
+#define RIFF 0x52494646
+#define WAVE 0x57415645
+#define FMT 0x666D7420
+#define DATA 0x64617461
+#define PCM_CODE (1 << 8)
+#define WAVE_MONO (1 << 8)
+#define WAVE_STEREO (2 << 8)
+
+#define MODE_MONO 0
+#define MODE_STEREO 1
+
+#endif
/********************/