same problem with dev-util/android-studio-22.214.171.124.162.3871768
Emulator never starts, because of libpulse.so.0 not found.
I don't use pulseaudio, but I have apulse installed for skype.
I could solve the problem and permit emulator to start linking like :
$ ls -l ~/Android/Sdk/emulator/lib*/libpulse.so.0
lrwxrwxrwx 1 chris users 31 16 mai 11:14 /home/chris/Android/Sdk/emulator/lib64/libpulse.so.0 -> /usr/lib64/apulse/libpulse.so.0
lrwxrwxrwx 1 chris users 31 16 mai 11:14 /home/chris/Android/Sdk/emulator/lib/libpulse.so.0 -> /usr/lib32/apulse/libpulse.so.0
I really don't know where the problem comes from.
$ ldd /opt/android-sdk-update-manager/emulator/qemu/linux-x86_64/qemu-system-x86_64 | grep pulse
libpulse.so.0 => /usr/lib64/libpulse.so.0 (0x00007fc947bf4000)
libpulsecommon-10.0.so => /usr/lib64/pulseaudio/libpulsecommon-10.0.so (0x00007fc9455ed000)
looks like the version of qemu in the SDK is linked with libpulse.so.0
doesnt apulse put its lib in the same path? it finds it fine with pulseaudio on my machine so it should work the same with apulse too?
What do you see if you ldd that same binary on your system?
Created attachment 506914 [details]
apulse libs are not put in the same directory as pulse but rather at /usr/lib64/apulse/. Reasoning behind this are binaries that support both pulseaudio and alsa, but prefer pulseaudio. In that case you don't want them to use apulse's pulseaudio wrappers. To support binaries link against only pulseaudio you have to set LD_LIBRARY_PATH or conveniently the wrapper /usr/bin/apulse, which does it for you.
I updated my fix for this to the latest version of android-studio in gentoo. With this emulator still throws some errors like
12:33 Emulator: pulseaudio: set_source_mute() failed
12:33 Emulator: pulseaudio: Reason: Oops.
but besides works fine.