How compile a plugin for pidgin

Florian Schmidt mista.tapas at gmx.net
Thu May 10 14:08:45 EDT 2007


On Tuesday 08 May 2007, dolphin dolphin wrote:
> Hello,
>
> I want to write a pidgin's plugin. I start with the code of autoaccept
> plugin for learn. I simplify it. But I don't know/understand how compile
> this source code. I write this makefile. (I'm under linux ubuntu dapper
> drake).
>
> GLIB_CFLAGS = -pthread -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include
> GLIB_LIBS = -Wl,--export-dynamic -pthread -lgobject-2.0 -lgmodule-2.0 -ldl
> - lgthread-2.0 -lglib-2.0
>
> install:plugin.so
>     cp -fv plugin.so /home/user/.purple/plugins/plugin.so
>     cp -fv plugin.la /home/user/.purple/plugins/plugin.la
>
> plugin.so: plugin.cc
>     g++ -shared -o plugin.so plugin.cc $(GLIB_CFLAGS) $(GLIB_LIBS)
>
> clean:
>     find . -name "*.*~" -exec rm {} \;
>     find . -name "plugin.so" -exec rm {} \;
>     find . -name "plugin.la" -exec rm {} \;
>     find /home/user/.purple/plugins/ -name "plugin.so" -exec rm {} \;
>
> the lib compile but when I launch pidgin with -d flags I obtain this error
> message
>
> plugins: /home/user/.purple/plugins/plugin.so is not usable because the
> 'purple_init_plugin' symbol could not be found.  Does the plugin call the
> PURPLE_INIT_PLUGIN() macro?
>
> I write the code
>
> PURPLE_INIT_PLUGIN(PLUGIN_STATIC_NAME, init_plugin, info)
>
> in the source code.
>
> thanks for your help

Hi,
you might look at the source and the makefile of this little plugin i wrote:

http://tapas.affenbande.org/wordpress/?page_id=70

Have fun,
Flo

-- 
Palimm Palimm!
http://tapas.affenbande.org



More information about the Devel mailing list