More flexible audio card selection
authormalc <malc@c046a42c-6fe2-441c-8c8c-71466251a162>
Fri, 9 Jan 2009 10:46:34 +0000 (10:46 +0000)
committermalc <malc@c046a42c-6fe2-441c-8c8c-71466251a162>
Fri, 9 Jan 2009 10:46:34 +0000 (10:46 +0000)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6258 c046a42c-6fe2-441c-8c8c-71466251a162

configure
vl.c

index 0d18534..adfdb47 100755 (executable)
--- a/configure
+++ b/configure
@@ -27,7 +27,8 @@ static="no"
 cross_prefix=""
 cc="gcc"
 audio_drv_list=""
-audio_card_list=""
+audio_card_list="ac97 es1370 sb16"
+audio_possible_cards="ac97 es1370 sb16 cs4231a adlib gus"
 host_cc="gcc"
 ar="ar"
 make="make"
@@ -519,8 +520,8 @@ echo "  --disable-sdl            disable SDL"
 echo "  --enable-cocoa           enable COCOA (Mac OS X only)"
 echo "  --audio-drv-list=LIST    set audio drivers list:"
 echo "                           Available drivers: $audio_possible_drivers"
-echo "  --audio-card-list=LIST   set list of additional emulated audio cards"
-echo "                           Available cards: ac97 adlib cs4231a gus"
+echo "  --audio-card-list=LIST   set list of emulated audio cards [$audio_card_list]"
+echo "                           Available cards: $audio_possible_cards"
 echo "  --enable-mixemu          enable mixer emulation"
 echo "  --disable-brlapi         disable BrlAPI"
 echo "  --disable-vnc-tls        disable TLS encryption for VNC server"
diff --git a/vl.c b/vl.c
index 9a9410b..e29072b 100644 (file)
--- a/vl.c
+++ b/vl.c
@@ -4266,6 +4266,8 @@ struct soundhw soundhw[] = {
         { .init_isa = pcspk_audio_init }
     },
 #endif
+
+#ifdef CONFIG_SB16
     {
         "sb16",
         "Creative Sound Blaster 16",
@@ -4273,6 +4275,7 @@ struct soundhw soundhw[] = {
         1,
         { .init_isa = SB16_init }
     },
+#endif
 
 #ifdef CONFIG_CS4231A
     {
@@ -4308,6 +4311,7 @@ struct soundhw soundhw[] = {
     },
 #endif
 
+#ifdef CONFIG_AC97
     {
         "ac97",
         "Intel 82801AA AC97 Audio",
@@ -4315,7 +4319,9 @@ struct soundhw soundhw[] = {
         0,
         { .init_pci = ac97_init }
     },
+#endif
 
+#ifdef CONFIG_ES1370
     {
         "es1370",
         "ENSONIQ AudioPCI ES1370",
@@ -4325,6 +4331,8 @@ struct soundhw soundhw[] = {
     },
 #endif
 
+#endif /* HAS_AUDIO_CHOICE */
+
     { NULL, NULL, 0, 0, { NULL } }
 };