summaryrefslogtreecommitdiff
path: root/sys/oss
diff options
context:
space:
mode:
authorStéphane Loeuillet <gstreamer@leroutier.net>2004-06-07 13:40:08 +0000
committerStéphane Loeuillet <gstreamer@leroutier.net>2004-06-07 13:40:08 +0000
commitef2468c353358aa89a32d7f596ae4f635e797304 (patch)
treed6a6a3a545d0a89cf0cb90e8e6435a60d6c89cfc /sys/oss
parenta6659f8a245ce35a58d97bf8327fd35d13a60925 (diff)
configure.ac: OSS portability
Original commit message from CVS: * configure.ac: OSS portability * ext/arts/gst_arts.c: idem * sys/oss/gstosselement.c: idem * sys/oss/gstossmixer.c: idem * sys/oss/gstosssink.c: idem * sys/oss/gstosssrc.c: idem * sys/oss/oss_probe.c: idem - check for soundcard.h in different places for some BSD
Diffstat (limited to 'sys/oss')
-rw-r--r--sys/oss/gstosselement.c29
-rw-r--r--sys/oss/gstossmixer.c13
-rw-r--r--sys/oss/gstosssink.c15
-rw-r--r--sys/oss/gstosssrc.c15
-rw-r--r--sys/oss/oss_probe.c19
5 files changed, 87 insertions, 4 deletions
diff --git a/sys/oss/gstosselement.c b/sys/oss/gstosselement.c
index 4c3512f1e..0e57d47fa 100644
--- a/sys/oss/gstosselement.c
+++ b/sys/oss/gstosselement.c
@@ -29,11 +29,24 @@
#include <sys/stat.h>
#include <sys/ioctl.h>
#include <fcntl.h>
-#include <sys/soundcard.h>
#include <unistd.h>
#include <errno.h>
#include <string.h>
+#ifdef HAVE_OSS_INCLUDE_IN_SYS
+#include <sys/soundcard.h>
+#else
+
+#ifdef HAVE_OSS_INCLUDE_IN_ROOT
+#include <soundcard.h>
+#else
+
+#include <machine/soundcard.h>
+
+#endif /* HAVE_OSS_INCLUDE_IN_ROOT */
+
+#endif /* HAVE_OSS_INCLUDE_IN_SYS */
+
#include <gst/propertyprobe/propertyprobe.h>
#include "gstosselement.h"
@@ -987,7 +1000,21 @@ gst_osselement_change_state (GstElement * element)
#if 0
+
+#ifdef HAVE_OSS_INCLUDE_IN_SYS
#include <sys/soundcard.h>
+#else
+
+#ifdef HAVE_OSS_INCLUDE_IN_ROOT
+#include <soundcard.h>
+#else
+
+#include <machine/soundcard.h>
+
+#endif /* HAVE_OSS_INCLUDE_IN_ROOT */
+
+#endif /* HAVE_OSS_INCLUDE_IN_SYS */
+
#include <unistd.h>
#include <fcntl.h>
#include <stdio.h>
diff --git a/sys/oss/gstossmixer.c b/sys/oss/gstossmixer.c
index 39b0d7c7d..274d12052 100644
--- a/sys/oss/gstossmixer.c
+++ b/sys/oss/gstossmixer.c
@@ -30,7 +30,20 @@
#include <string.h>
#include <errno.h>
#include <sys/ioctl.h>
+
+#ifdef HAVE_OSS_INCLUDE_IN_SYS
#include <sys/soundcard.h>
+#else
+
+#ifdef HAVE_OSS_INCLUDE_IN_ROOT
+#include <soundcard.h>
+#else
+
+#include <machine/soundcard.h>
+
+#endif /* HAVE_OSS_INCLUDE_IN_ROOT */
+
+#endif /* HAVE_OSS_INCLUDE_IN_SYS */
#include "gstossmixer.h"
diff --git a/sys/oss/gstosssink.c b/sys/oss/gstosssink.c
index befb57fd8..1f9e6ff94 100644
--- a/sys/oss/gstosssink.c
+++ b/sys/oss/gstosssink.c
@@ -24,11 +24,24 @@
#include "config.h"
#endif
#include <sys/ioctl.h>
-#include <sys/soundcard.h>
#include <errno.h>
#include <unistd.h>
#include <string.h>
+#ifdef HAVE_OSS_INCLUDE_IN_SYS
+#include <sys/soundcard.h>
+#else
+
+#ifdef HAVE_OSS_INCLUDE_IN_ROOT
+#include <soundcard.h>
+#else
+
+#include <machine/soundcard.h>
+
+#endif /* HAVE_OSS_INCLUDE_IN_ROOT */
+
+#endif /* HAVE_OSS_INCLUDE_IN_SYS */
+
#include "gstosssink.h"
/* elementfactory information */
diff --git a/sys/oss/gstosssrc.c b/sys/oss/gstosssrc.c
index 5b44823cf..31d9fc1ce 100644
--- a/sys/oss/gstosssrc.c
+++ b/sys/oss/gstosssrc.c
@@ -26,12 +26,25 @@
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
-#include <sys/soundcard.h>
#include <sys/ioctl.h>
#include <errno.h>
#include <unistd.h>
#include <string.h>
+#ifdef HAVE_OSS_INCLUDE_IN_SYS
+#include <sys/soundcard.h>
+#else
+
+#ifdef HAVE_OSS_INCLUDE_IN_ROOT
+#include <soundcard.h>
+#else
+
+#include <machine/soundcard.h>
+
+#endif /* HAVE_OSS_INCLUDE_IN_ROOT */
+
+#endif /* HAVE_OSS_INCLUDE_IN_SYS */
+
#include <gstosssrc.h>
#include <gstosselement.h>
#include <gst/audio/audioclock.h>
diff --git a/sys/oss/oss_probe.c b/sys/oss/oss_probe.c
index 741bb4c72..5b0d12845 100644
--- a/sys/oss/oss_probe.c
+++ b/sys/oss/oss_probe.c
@@ -1,5 +1,8 @@
-#include <sys/soundcard.h>
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+
#include <unistd.h>
#include <fcntl.h>
#include <stdio.h>
@@ -7,6 +10,20 @@
#include <sys/ioctl.h>
#include <glib.h>
+#ifdef HAVE_OSS_INCLUDE_IN_SYS
+#include <sys/soundcard.h>
+#else
+
+#ifdef HAVE_OSS_INCLUDE_IN_ROOT
+#include <soundcard.h>
+#else
+
+#include <machine/soundcard.h>
+
+#endif /* HAVE_OSS_INCLUDE_IN_ROOT */
+
+#endif /* HAVE_OSS_INCLUDE_IN_SYS */
+
typedef struct _Probe Probe;
struct _Probe
{