Hi all,
I've compiled version 2.2.1 from svn, it seems to work just fine but I can't for the life of me get it to output any sound. During startup, I get a "Unable to open audio!" message during the sound initialization. Running it with strace reveals several "Cannot allocate memory" (ENOMEM) errors that seem to be the cause of the problem. Changing the SDL_AUDIODRIVER from alsa to dsp didn't help (strace ouput changes since we open different devices, etc, but it still fails with ENOMEM). Just to confirm, I hacked src/client/cl_sound.c to add a perror() statement right after the call to Mix_OpenAudio() and the error returned was indeed "Cannot allocate memory".
Now comes the weird part. Sound works fine in other apps, so I figured it might've been an issue with my SDL installation or configuration, etc. I found an example test program here:
http://www.kekkai.org/roger/sdl/mixer/ (specifically mixer1.c). Surprisingly, it works just fine, which seems to indicate a working SDL install. The SDL function calls in that program are almost identical to that in cl_sound.c, so I can't imagine what might be going wrong. I even tried editing cl_sound.c to call Mix_OpenAudio with exactly the same arguments as that in the test program, no dice.
Any thoughts/suggestions would be most appreciated. Thanks!
Some stuff about my system:
Distro: Gentoo
Arch: x86 (Core 2 Duo @ 2.0Ghz, 4GB Ram)
Kernel: 2.6.29-gentoo-r5, alsa drivers compiled in w/ oss emulation support
SDL module versions: Mixer (1.2.
, Sound (1.0.3), TTF (2.0.9), libSDL (1.2.13-r1)
Graphics: Nvidia Quadro NVS 140m w/ binary Nvidia driver
p.s. I tried installing with the Gentoo ebuild in case there were some Gentoo-specific customizations that needed to be made, but I still get the same error.