Skip to contentSkip to conversation

Patch: allow Solaris to use OSS (OpenSound)

Qemu-devel Ben Taylor 2 participants 2 messages Feb 26, 2007

lore
Share & tools
lore

Ben Taylor

author
#0 lore raw

As I seem to have hit a wall with the ES1370 driver in qemu not working on Solaris, I have modified configure to allow Solaris to use OpenSoundSystems audio.

Is there any interest in having a default audio setting for SDL so that you won't have to always put QEMU_SDL_AUDIO=oss before you start qemu?

Ben

configure +13 -0
diff -ruN qemu-ORIG/configure qemu/configure
@@ -221,6 +221,8 @@
   ;;
   --fmod-inc=*) fmod_inc="$optarg"
   ;;
+  --enable-oss) oss="yes"
+  ;;
   --enable-mingw32) mingw32="yes" ; cross_prefix="i386-mingw32-" ; linux_user="no"
   ;;
   --disable-slirp) slirp="no"
@@ -289,6 +291,7 @@
 echo "  --enable-coreaudio       enable Coreaudio audio driver"
 echo "  --enable-alsa            enable ALSA audio driver"
 echo "  --enable-fmod            enable FMOD audio driver"
+echo "  --enable-oss             enable OSS audio driver"
 echo "  --enabled-dsound         enable DirectSound audio driver"
 echo "  --enable-system          enable all system emulation targets"
 echo "  --disable-system         disable all system emulation targets"
@@ -619,6 +622,16 @@
     fmod_support=""
 fi
 echo "FMOD support      $fmod $fmod_support"
+if test "$oss" = "yes"; then
+    if test "$solaris" = "yes" && ! test -f /usr/include/sys/soundcard.h ; then
+        echo
+        echo "Error: /usr/include/sys/soundcard.h not found"
+        echo "Error: You must install OSS to use the oss module"
+        echo
+        exit 1
+    fi
+fi
+echo "OSS support       $oss"
 echo "kqemu support     $kqemu"
 echo "Documentation     $build_docs"
 [ ! -z "$uname_release" ] && \
#1 lore raw
Quoted 8 lines · Ben Taylor

As I seem to have hit a wall with the ES1370 driver in qemu not working on Solaris, I have modified configure to allow Solaris to use OpenSoundSystems audio.

Is there any interest in having a default audio setting for SDL so that you won't have to always put QEMU_SDL_AUDIO=oss before you start qemu?

I don't quite get what does not work OSS or ES1370?

An aside. To the best of my knowledge OSS on Solaris, Net/OpenBSD (FreeBSDs OSS is fine though) is not your usual OSS but some reduced version which among other things only allows one open per device (meaning that to do both DAC/ADC one has to use single file descriptor)

Quoted 1 line

From where i stand SDL as the default is a bad idea.

Signature · 1 line
vale