[vlc-commits] OSS: fix FreeBSD 8 compilation
Rémi Denis-Courmont
git at videolan.org
Sun Jul 22 17:21:23 CEST 2012
vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Sun Jul 22 18:21:09 2012 +0300| [4977733cd76e2871e4399050d896fd7375d31497] | committer: Rémi Denis-Courmont
OSS: fix FreeBSD 8 compilation
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=4977733cd76e2871e4399050d896fd7375d31497
---
modules/audio_output/oss.c | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/modules/audio_output/oss.c b/modules/audio_output/oss.c
index dba3f2b..2dd0b5e 100644
--- a/modules/audio_output/oss.c
+++ b/modules/audio_output/oss.c
@@ -38,6 +38,10 @@
# include <sys/soundcard.h>
#endif
+#ifndef SNDCTL_DSP_HALT
+# define SNDCTL_DSP_HALT SNDCTL_DSP_RESET
+#endif
+
#include <vlc_common.h>
#include <vlc_plugin.h>
#include <vlc_fs.h>
@@ -113,12 +117,14 @@ static int Open (vlc_object_t *obj)
switch (fourcc)
{
+#ifdef AFMT_FLOAT
case VLC_CODEC_F64B:
case VLC_CODEC_F64L:
case VLC_CODEC_F32B:
case VLC_CODEC_F32L:
format = AFMT_FLOAT;
break;
+#endif
case VLC_CODEC_S32B:
format = AFMT_S32_BE;
break;
@@ -140,8 +146,10 @@ static int Open (vlc_object_t *obj)
spdif = var_InheritBool (aout, "spdif");
if (spdif)
format = AFMT_AC3;
+#ifdef AFMT_FLOAT
else if (HAVE_FPU)
format = AFMT_FLOAT;
+#endif
else
format = AFMT_S16_NE;
}
@@ -162,7 +170,9 @@ static int Open (vlc_object_t *obj)
//case AFMT_S24_LE:
case AFMT_S32_BE: fourcc = VLC_CODEC_S32B; break;
case AFMT_S32_LE: fourcc = VLC_CODEC_S32L; break;
+#ifdef AFMT_FLOAT
case AFMT_FLOAT: fourcc = VLC_CODEC_FL32; break;
+#endif
case AFMT_AC3:
if (spdif)
{
More information about the vlc-commits
mailing list