Skip to contentSkip to conversation

[4827] Pulseaudio driver

Qemu-devel malc 1 participant 1 message Jul 2, 2008 Kbuild

lore
Share & tools
lore

malc

author
#0 lore raw

Revision: 4827

          http://svn.sv.gnu.org/viewvc/?view=rev&root=qemu&revision=4827
Author:   malc
Date:     2008-07-02 21:03:08 +0000 (Wed, 02 Jul 2008)

Log Message:
-----------
Pulseaudio driver

Modified Paths:
--------------
trunk/Makefile
trunk/Makefile.target
trunk/audio/audio_int.h
trunk/configure

Added Paths:
-----------
trunk/audio/paaudio.c

Modified: trunk/Makefile
===================================================================

Makefile +5 -0
@@ -98,6 +98,11 @@
 AUDIO_PT_INT = yes
 AUDIO_OBJS += esdaudio.o
 endif
+ifdef CONFIG_PA
+AUDIO_PT = yes
+AUDIO_PT_INT = yes
+AUDIO_OBJS += paaudio.o
+endif
 ifdef AUDIO_PT
 LDFLAGS += -pthread
 endif

Modified: trunk/Makefile.target
===================================================================

Makefile.target +4 -0
@@ -270,6 +270,7 @@
 	$(AR) rcs $@ $(LIBOBJS)
 
 translate.o: translate.c cpu.h $(OPC_H)
+translate.o: CFLAGS:=${CFLAGS} -O1 #-fno-unit-at-a-time
 
 translate-all.o: translate-all.c cpu.h $(OPC_H)
 
@@ -480,6 +481,9 @@
 ifdef CONFIG_ESD
 LIBS += -lesd
 endif
+ifdef CONFIG_PA
+LIBS += -lpulse-simple
+endif
 ifdef CONFIG_DSOUND
 LIBS += -lole32 -ldxguid
 endif

Modified: trunk/audio/audio_int.h
===================================================================

audio/audio_int.h +1 -0
@@ -203,6 +203,7 @@
 extern struct audio_driver coreaudio_audio_driver;
 extern struct audio_driver dsound_audio_driver;
 extern struct audio_driver esd_audio_driver;
+extern struct audio_driver pa_audio_driver;
 extern volume_t nominal_volume;
 
 void audio_pcm_init_info (struct audio_pcm_info *info, audsettings_t *as);

Added: trunk/audio/paaudio.c
===================================================================

audio/paaudio.c +515 -0

515 lines not on this page · raw message

Modified: trunk/configure
===================================================================

configure +7 -1
@@ -196,7 +196,7 @@
 ;;
 *)
 audio_drv_list="oss"
-audio_possible_drivers="oss alsa sdl esd"
+audio_possible_drivers="oss alsa sdl esd pa"
 linux="yes"
 linux_user="yes"
 if [ "$cpu" = "i386" -o "$cpu" = "x86_64" ] ; then
@@ -767,6 +767,12 @@
     esd)
     audio_drv_probe $drv esd.h -lesd 'return esd_play_stream(0, 0, "", 0);'
     ;;
+
+    pa)
+    audio_drv_probe $drv pulse/simple.h -lpulse-simple \
+        "pa_simple *s = NULL; pa_simple_free(s); return 0;"
+    ;;
+
     esac
 done