Subject: Side-effects dlopening libstdc++?
To: None <firstname.lastname@example.org, email@example.com>
From: Julio M. Merino Vidal <firstname.lastname@example.org>
Date: 11/10/2004 22:43:47
beep-media-player crashes when it is closed. During shutdown, it dlclose(3)s
all plugins that were loaded during initialization, and the first call to this
function causes a segfault.
One of the plugins (mpg123) is linked against id3lib, which in turn uses
libstdc++. However, if id3lib support is disabled in the mpg123 plugin,
the crash does not happen.
Furthermore, if I compile the whole bmp package with -lstdc++ in LDFLAGS
(and id3lib support enabled), the crash does not happen. This reminds me
of the -lpthread problem (where you can't dlopen it from a non-threaded
program)... does this make any sense? I mean, can't libstdc++ be dlopened
without side effects in a non-c++ program? If not, may this be a bug in
our dynamic loading code?
Julio M. Merino Vidal <email@example.com>
The NetBSD Project - http://www.NetBSD.org/