gstreamer/tests/old/testsuite/dlopen/dlopen_gst.c
Thomas Vander Stichele c00b874061 #ifdef new symbol
Original commit message from CVS:
#ifdef new symbol
2004-04-23 09:21:24 +00:00

28 lines
546 B
C

#include <gmodule.h>
int
main (int argc, char *argv[])
{
GModule *module;
void (*symbol) (void);
gboolean ret;
module = g_module_open (".libs/libloadgst.so",
#ifdef HAVE_G_MODULE_BIND_LOCAL
G_MODULE_BIND_LOCAL |
#endif
G_MODULE_BIND_LAZY);
g_assert (module != NULL);
ret = g_module_symbol (module, "gst_init", (gpointer *) & symbol);
g_print ("'gst_init' is %s\n", ret ? "visible" : "not visible");
ret = g_module_symbol (module, "do_test", (gpointer *) & symbol);
g_assert (ret);
symbol ();
exit (0);
}