No sound in Qemu PPC OS 9.22.

About Qemu-system-ppc, a PPC Mac emulator for Windows, macOS and Linux that can run Mac OS 9.0 up to Mac OS X 10.5

Moderators: Cat_7, Ronald P. Regensburg

Post Reply
macjack123
Student Driver
Posts: 12
Joined: Wed Jun 12, 2019 4:22 am

No sound in Qemu PPC OS 9.22.

Post by macjack123 »

Hi i booted successfully into OS 9.22 but there is no sound, can you please help me configure it.
Here is my script
qemu-system-ppc \
-boot c \
-M mac99,via=pmu \
-m 1500M \
-cpu G3 \
-prom-env 'auto-boot?=true' -prom-env 'boot-args=-v' -prom-env 'vga-ndrv?=true' \
-prom-env 'vga-ndrv?=true' \
-drive file="MacOS9.2.img",\
format=raw,index=0,media=disk \
-name "Mac OS 9.2.1" \
-no-reboot\
User avatar
adespoton
Forum All-Star
Posts: 4226
Joined: Fri Nov 27, 2009 5:11 am
Location: Emaculation.com
Contact:

Re: No sound in Qemu PPC OS 9.22.

Post by adespoton »

Which version of QEMU are you running? If you're using sound, you're going to want "08-02-2019: Qemu 4.0pre with altivec acceleration and screamer audio support" from viewtopic.php?f=34&t=8848

Otherwise, you're limited to USB-audio, and will need to set that up as a config flag.
macjack123
Student Driver
Posts: 12
Joined: Wed Jun 12, 2019 4:22 am

Re: No sound in Qemu PPC OS 9.22.

Post by macjack123 »

I am using qemu version 4, is the above link for qemu versions only applicable to mac os?
User avatar
Cat_7
Expert User
Posts: 6145
Joined: Fri Feb 13, 2004 8:59 am
Location: Sittard, The Netherlands

Re: No sound in Qemu PPC OS 9.22.

Post by Cat_7 »

Yes,
But we have sound-supporting builds available for Windows and OSX/MacOS

If you compile yourself in e.g., Linux, then you need to compile from this branch:
https://github.com/mcayland/qemu/tree/screamer

Best,
Cat_7
macjack123
Student Driver
Posts: 12
Joined: Wed Jun 12, 2019 4:22 am

Re: No sound in Qemu PPC OS 9.22.

Post by macjack123 »

Do i need to pass any command in the qemu bash file to enable sound ?
User avatar
Cat_7
Expert User
Posts: 6145
Joined: Fri Feb 13, 2004 8:59 am
Location: Sittard, The Netherlands

Re: No sound in Qemu PPC OS 9.22.

Post by Cat_7 »

No,

If you use any of the sound-enabled builds we provide, it should be enabled by default.
Same for builds from source in Linux. Oh, you might need to set QEMU_AUDIO_DRV=pa in the bash file if your Linux uses PulseAudio.

Best,
Cat_7
macjack123
Student Driver
Posts: 12
Joined: Wed Jun 12, 2019 4:22 am

Re: No sound in Qemu PPC OS 9.22.

Post by macjack123 »

I am getting a following build error when running make,

CC util/qemu-sockets.o
In file included from /usr/include/string.h:494,
from /home/shank/osX/tiger/qemu/include/qemu/osdep.h:69,
from /home/shank/osX/tiger/qemu/util/qemu-sockets.c:18:
In function ‘strncpy’,
inlined from ‘unix_connect_saddr.isra.0’ at /home/shank/osX/tiger/qemu/util/qemu-sockets.c:925:5:
/usr/include/bits/string_fortified.h:106:10: error: ‘__builtin_strncpy’ specified bound 108 equals destination size [-Werror=stringop-truncation]
106 | return __builtin___strncpy_chk (__dest, __src, __len, __bos (__dest));
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In function ‘strncpy’,
inlined from ‘unix_listen_saddr.isra.0’ at /home/shank/osX/tiger/qemu/util/qemu-sockets.c:880:5:
/usr/include/bits/string_fortified.h:106:10: error: ‘__builtin_strncpy’ specified bound 108 equals destination size [-Werror=stringop-truncation]
106 | return __builtin___strncpy_chk (__dest, __src, __len, __bos (__dest));
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
make: *** [/home/shank/osX/tiger/qemu/rules.mak:69: util/qemu-sockets.o] Error 1
User avatar
Cat_7
Expert User
Posts: 6145
Joined: Fri Feb 13, 2004 8:59 am
Location: Sittard, The Netherlands

Re: No sound in Qemu PPC OS 9.22.

Post by Cat_7 »

Yes, the latest gcc handles these more stringent. It seems the screamer code has not been rebased on the latest qemu source.

add --disable-werror to the configure options and build.

Best,
Cat_7
macjack123
Student Driver
Posts: 12
Joined: Wed Jun 12, 2019 4:22 am

Re: No sound in Qemu PPC OS 9.22.

Post by macjack123 »

oh thx i went further with compilation but now I am getting this error

https://pastebin.com/rEWwdBKs
User avatar
Cat_7
Expert User
Posts: 6145
Joined: Fri Feb 13, 2004 8:59 am
Location: Sittard, The Netherlands

Re: No sound in Qemu PPC OS 9.22.

Post by Cat_7 »

I have no idea why that occurs.

I just recompiled the screamer branch, I do not even get the errors mentioned earlier.
Host is Fedora 30, gcc version 9.1.1 20190503 (Red Hat 9.1.1-1) (GCC)
These are my compilation steps:

git clone -b screamer https://github.com/mcayland/qemu qemu-screamer
cd qemu-screamer
./configure --target-list="ppc-softmmu" --enable-sdl --enable-gtk && make -j8
Post Reply