libpurple/plugins/perl/libpurpleperl.c

Mon, 16 Apr 2007 00:44:33 +0000

author
Richard Laager <rlaager@pidgin.im>
date
Mon, 16 Apr 2007 00:44:33 +0000
changeset 16238
33bf2fd32108
parent 12418
plugins/perl/libgaimperl.c@77abb6df8ee6
parent 15987
plugins/perl/libgaimperl.c@71d668c3d56d
permissions
-rw-r--r--

merge of 'b98e72d4089afb8a1879e5fe9627cfb132ee88de'
and '606a402fea87c797c4b751475228a6f6a5385122'

#include <gmodule.h>

#ifdef  __SUNPRO_C
#pragma init (my_init)
void my_init(void);

void my_init() {
#else
void __attribute__ ((constructor)) my_init(void);

void __attribute__ ((constructor)) my_init() {
#endif

	/* Very evil hack...puts perl.so's symbols in the global table
	 * but does not create a circular dependancy because g_module_open
	 * will only open the library once. */
	g_module_open("perl.so", 0);
}

mercurial