$OpenBSD: patch-app_drivers_oss_output_c,v 1.1.1.1 2002/02/05 18:04:10 espie Exp $
--- app/drivers/oss-output.c.orig	Sat Aug  4 07:06:18 2001
+++ app/drivers/oss-output.c	Mon Feb  4 04:17:56 2002
@@ -32,7 +32,13 @@
 #include <sys/ioctl.h>
 #include <sys/types.h>
 #include <unistd.h>
-#include <sys/soundcard.h>
+#ifdef HAVE_SYS_SOUNDCARD_H
+# include <sys/soundcard.h>
+#elif HAVE_MACHINE_SOUNDCARD_H
+# include <machine/soundcard.h>
+#elif HAVE_SOUNDCARD_H
+# include <soundcard.h>
+#endif
 #include <sys/time.h>
 
 #include <glib.h>
@@ -61,7 +67,7 @@ typedef struct oss_driver {
     int mf;
     gboolean realtimecaps;
 
-    GMutex *configmutex;
+    pthread_mutex_t configmutex;
 
     int soundfd;
     void *sndbuf;
@@ -307,7 +313,9 @@ oss_new (void)
     d->soundfd = -1;
     d->sndbuf = NULL;
     d->polltag = NULL;
-    d->configmutex = g_mutex_new();
+    if (pthread_mutex_init(&d->configmutex, NULL) != 0) {
+        return (NULL);
+    }
 
     oss_make_config_widgets(d);
 
@@ -320,7 +328,7 @@ oss_destroy (void *dp)
     oss_driver * const d = dp;
 
     gtk_widget_destroy(d->configwidget);
-    g_mutex_free(d->configmutex);
+    pthread_mutex_destroy(&d->configmutex);
 
     g_free(dp);
 }
