Commit 2f6a1ab038eefd6e5a9cfc8ec49435f6ad025812
1 parent
363a37d5
Fix OSS on OpenBSD
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5045 c046a42c-6fe2-441c-8c8c-71466251a162
Showing
2 changed files
with
14 additions
and
5 deletions
Makefile.target
@@ -495,6 +495,9 @@ endif | @@ -495,6 +495,9 @@ endif | ||
495 | ifdef CONFIG_FMOD | 495 | ifdef CONFIG_FMOD |
496 | LIBS += $(CONFIG_FMOD_LIB) | 496 | LIBS += $(CONFIG_FMOD_LIB) |
497 | endif | 497 | endif |
498 | +ifdef CONFIG_OSS | ||
499 | +LIBS += $(CONFIG_OSS_LIB) | ||
500 | +endif | ||
498 | 501 | ||
499 | SOUND_HW = sb16.o es1370.o | 502 | SOUND_HW = sb16.o es1370.o |
500 | ifdef CONFIG_AC97 | 503 | ifdef CONFIG_AC97 |
configure
@@ -92,6 +92,7 @@ slirp="yes" | @@ -92,6 +92,7 @@ slirp="yes" | ||
92 | vde="yes" | 92 | vde="yes" |
93 | fmod_lib="" | 93 | fmod_lib="" |
94 | fmod_inc="" | 94 | fmod_inc="" |
95 | +oss_lib="" | ||
95 | vnc_tls="yes" | 96 | vnc_tls="yes" |
96 | bsd="no" | 97 | bsd="no" |
97 | linux="no" | 98 | linux="no" |
@@ -153,6 +154,7 @@ bsd="yes" | @@ -153,6 +154,7 @@ bsd="yes" | ||
153 | openbsd="yes" | 154 | openbsd="yes" |
154 | audio_drv_list="oss" | 155 | audio_drv_list="oss" |
155 | audio_possible_drivers="oss sdl esd" | 156 | audio_possible_drivers="oss sdl esd" |
157 | +oss_lib="-lossaudio" | ||
156 | ;; | 158 | ;; |
157 | Darwin) | 159 | Darwin) |
158 | bsd="yes" | 160 | bsd="yes" |
@@ -273,6 +275,8 @@ for opt do | @@ -273,6 +275,8 @@ for opt do | ||
273 | ;; | 275 | ;; |
274 | --fmod-inc=*) fmod_inc="$optarg" | 276 | --fmod-inc=*) fmod_inc="$optarg" |
275 | ;; | 277 | ;; |
278 | + --oss-lib=*) oss_lib="$optarg" | ||
279 | + ;; | ||
276 | --audio-card-list=*) audio_card_list=`echo "$optarg" | sed -e 's/,/ /g'` | 280 | --audio-card-list=*) audio_card_list=`echo "$optarg" | sed -e 's/,/ /g'` |
277 | ;; | 281 | ;; |
278 | --audio-drv-list=*) audio_drv_list="$optarg" | 282 | --audio-drv-list=*) audio_drv_list="$optarg" |
@@ -437,6 +441,7 @@ echo " --enable-darwin-user enable all darwin usermode emulation targets" | @@ -437,6 +441,7 @@ echo " --enable-darwin-user enable all darwin usermode emulation targets" | ||
437 | echo " --disable-darwin-user disable all darwin usermode emulation targets" | 441 | echo " --disable-darwin-user disable all darwin usermode emulation targets" |
438 | echo " --fmod-lib path to FMOD library" | 442 | echo " --fmod-lib path to FMOD library" |
439 | echo " --fmod-inc path to FMOD includes" | 443 | echo " --fmod-inc path to FMOD includes" |
444 | +echo " --oss-lib path to OSS library" | ||
440 | echo " --enable-uname-release=R Return R for uname -r in usermode emulation" | 445 | echo " --enable-uname-release=R Return R for uname -r in usermode emulation" |
441 | echo " --sparc_cpu=V Build qemu for Sparc architecture v7, v8, v8plus, v8plusa, v9" | 446 | echo " --sparc_cpu=V Build qemu for Sparc architecture v7, v8, v8plus, v8plusa, v9" |
442 | echo " --disable-vde disable support for vde network" | 447 | echo " --disable-vde disable support for vde network" |
@@ -823,6 +828,10 @@ for drv in $audio_drv_list; do | @@ -823,6 +828,10 @@ for drv in $audio_drv_list; do | ||
823 | "pa_simple *s = NULL; pa_simple_free(s); return 0;" | 828 | "pa_simple *s = NULL; pa_simple_free(s); return 0;" |
824 | ;; | 829 | ;; |
825 | 830 | ||
831 | + oss|sdl|core|wav|dsound) | ||
832 | + # XXX: Probes for CoreAudio, DirectSound, SDL(?) | ||
833 | + ;; | ||
834 | + | ||
826 | *) | 835 | *) |
827 | echo "$audio_possible_drivers" | grep -q "\<$drv\>" || { | 836 | echo "$audio_possible_drivers" | grep -q "\<$drv\>" || { |
828 | echo | 837 | echo |
@@ -832,11 +841,6 @@ for drv in $audio_drv_list; do | @@ -832,11 +841,6 @@ for drv in $audio_drv_list; do | ||
832 | exit 1 | 841 | exit 1 |
833 | } | 842 | } |
834 | ;; | 843 | ;; |
835 | - | ||
836 | - oss|sdl|core|wav|dsound) | ||
837 | - # XXX: Probes for CoreAudio, DirectSound, SDL(?) | ||
838 | - ;; | ||
839 | - | ||
840 | esac | 844 | esac |
841 | done | 845 | done |
842 | 846 | ||
@@ -1145,6 +1149,8 @@ for drv in $audio_drv_list; do | @@ -1145,6 +1149,8 @@ for drv in $audio_drv_list; do | ||
1145 | if test "$drv" = "fmod"; then | 1149 | if test "$drv" = "fmod"; then |
1146 | echo "CONFIG_FMOD_LIB=$fmod_lib" >> $config_mak | 1150 | echo "CONFIG_FMOD_LIB=$fmod_lib" >> $config_mak |
1147 | echo "CONFIG_FMOD_INC=$fmod_inc" >> $config_mak | 1151 | echo "CONFIG_FMOD_INC=$fmod_inc" >> $config_mak |
1152 | + elif test "$drv" = "oss"; then | ||
1153 | + echo "CONFIG_OSS_LIB=$oss_lib" >> $config_mak | ||
1148 | fi | 1154 | fi |
1149 | done | 1155 | done |
1150 | echo "" >>$config_h | 1156 | echo "" >>$config_h |