I’ve been trying to figure out this problem for the last couple days… it’s
really beginning to bug me. I have a simple program to play files using
SDL_mixer, and it worked on my old machine; but on my new machine, an AMD64,
it segfaults on Mix_OpenAudio. Recompiling SDL, SDL_mixer, and aRts for
maximum debug info produced this backtrace in gdb:
GNU gdb 6.0
Copyright 2003 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type “show copying” to see the conditions.
There is absolutely no warranty for GDB. Type “show warranty” for details.
This GDB was configured as “x86_64-pc-linux-gnu”…Using host libthread_d
library “/lib/libthread_db.so.1”.
(gdb) run
Starting program: /home/monttyle/code/SDL/sdlmix/sdlmix
[Thread debugging using libthread_db enabled]
[New Thread 16384 (LWP 20319)]
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 16384 (LWP 20319)]
0x0000002a97d4e8d9 in Arts::StartupManager::startup() () at stl_list.h:167
167 { return static_cast<_Node*>(_M_node)->_M_data; }
Current language: auto; currently c++
(gdb) bt f
#0 0x0000002a97d4e8d9 in Arts::StartupManager::startup() () at stl_list.h:167
i = {<_List_iterator_base> = {_M_node = 0x508110}, }
#1 0x0000002a97d31a23 in Dispatcher (this=0x51d8e8, ioManager=0x0,
startServer=noServer) at dispatcher.cc:221
env = 0x502d70 "?l?\227*“
envOk = 112
seedpath = {static npos = 18446744073709551615,
_M_dataplus = {<allocator> = {},
_M_p = 0xbfffef10 " XP”}, static _S_empty_rep_storage = {0, 0, 5, 0}}
mcopdir = {static npos = 18446744073709551615,
_M_dataplus = {<allocator> = {},
_M_p = 0x2a96d09512 “H\205?H\211?t\005H\211?[?H\203=??\020”},
static _S_empty_rep_storage = {0, 0, 5, 0}}
cookie = 0x513a70 "`?P"
secretCookie = {static npos = 18446744073709551615,
_M_dataplus = {<allocator> = {},
_M_p = 0xbfffed50 “”}, static _S_empty_rep_storage = {0, 0, 5, 0}}
i = {<iterator<std::random_access_iterator_tag,char,long int,char*,char&>> =
{}, _M_current = 0x502d70 “?l?\227*”}
#2 0x0000002a971e1406 in arts_backend_init () at artscbackend.cc:583
No locals.
#3 0x0000002a96d08f8a in arts_init () at artsc.c:128
rc = -2
—Type to continue, or q to quit—
#4 0x0000002a9567ef47 in ARTSC_OpenAudio (this=0x505ed0, spec=0x505f28)
at SDL_artsaudio.c:301
bits = 16
frag_spec = 5267240
test_format = 32784
format = 1
#5 0x0000002a956796ef in SDL_OpenAudio (desired=0xbffff2b0,
obtained=0x2a95ad8d80) at SDL_audio.c:425
audio = (SDL_AudioDevice *) 0x505ed0
#6 0x0000002a95996627 in Mix_OpenAudio (frequency=44100, format=32784,
nchannels=2, chunksize=4096) at mixer.c:290
i = 0
desired = {freq = 44100, format = 32784, channels = 2 ‘\002’,
silence = 0 ‘\0’, samples = 4096, padding = 0, size = 16384,
callback = 0x2a95995b7d <mix_channels>, userdata = 0x0}
#7 0x0000000000400c88 in AudioInit() () at sdlmix.c:73
No locals.
#8 0x0000000000400a9b in main (argc=1, argv=0xbffff3b8) at sdlmix.c:20
n = -1
music = (Mix_Music *) 0x0
aRts seems to be crashing internally. Yet I have other applications that use
it to play sound and they work fine. What can I try next to help figure this
out?