GNOME Bugzilla – Bug 323718
[oss] does not build on OpenBSD 3.8 because of hardcoded <sys/soundcard.h>
Last modified: 2005-12-10 14:59:09 UTC
Distribution/Version: 3.8 Several files on gst-plugins-good-0.10.0 relies on OSS headers being <sys/soundcard.h>. This assumption is false on OpenBSD, where we should rather #include <soundcard.h> (not "sys/soundcard.h"): sys/oss/gstosshelper.c:#include <sys/soundcard.h> sys/oss/gstossmixer.c:#include <sys/soundcard.h> sys/oss/gstossmixertrack.c:#include <sys/soundcard.h> sys/oss/gstosssink.c:#include <sys/soundcard.h> sys/oss/gstosssrc.c:#include <sys/soundcard.h> Indeed, those files won't compile as is on OpenBSD. By the way, configure.ac has already "HAVE_OSS_INCLUDE_IN_ROOT" "HAVE_OSS_INCLUDE_IN_SYS" macros that works well here, and generate an apropriate config.h we could rely on to include this header from the right path. On OpenBSD, it gives such a config.h: /* Define if OSS includes are in / */ #define HAVE_OSS_INCLUDE_IN_ROOT /* Define if OSS includes are in /sys/ */ /* #undef HAVE_OSS_INCLUDE_IN_SYS */ ... and the opposite on my Debian GNU/Linux system. This being on OpenBSD 3.8, released on November 2005, so don't be fooled by configure.ac comment "dnl Some old BSD versions" ;).
Created attachment 55840 [details] [review] proposed fix Does this fix things for you?
Tim: the patches fix the problem, thanks ! Note: I've only tested on 0.10.0 release for now, so two patches are ignored because two files aren't present on this version (sys/oss/gstossdmabuffer.c and sys/oss/oss_probe.c). I will test on cvs HEAD soon (well, as soon as I figure how to make autogen.sh work, for now I miss autopoint, apparently).
Oh, sorry, gstossdmabuffer.c and gstossprobe.c are not used in CVS either (I just grepped and replaced)... Anyway, fixed in CVS. Thanks for the report.