This forum has been archived. All content is frozen. Please use KDE Discuss instead.

new plugin

Tags: None
(comma "," separated)
chr1syr
Registered Member
Posts
11
Karma
0

new plugin

Mon Jul 21, 2008 6:15 pm
Hi, Is there a how-to guide for the plugin interface and make process. I can't seem to find one. Ive tried making a new plugin by copying plugin/upnp to plugin/upnp2 and changing all references to upnp to upnp2 (including file names, and using sed). I also added upnp2 to the Makefile and edited automake. What do I need to do to get upnp2 to load as a plugin?

p.s.Im an average c programmer who needs a c++ project to use the language propper. I'm keen on being a developer for ktorrent as I think its one of the best torrent clients available. Thinking about a plugin to automatically ban peers that time waste for a pre set amount of time.
chr1syr
Registered Member
Posts
11
Karma
0

Tue Jul 22, 2008 7:19 pm
I guess its a case of RTFC and just keep on hacking till it works :P
George
Moderator
Posts
5421
Karma
1

Thu Jul 24, 2008 8:12 am
There isn't really any documentation on it. But it isn't that difficult, just copy from other plugins, make sure that the desktop file is installed and the library names are correct, and everything should work.
George
Moderator
Posts
5421
Karma
1

Fri Jul 25, 2008 8:55 am
Sam wrote:Hi George,

Neophyte linux person here, but long time programmer...

Could you be a tad more specific?

Standard paths
Needed libraries
How to include in make/compile
Any ktorrent specific quirks to look out for

All the usual suspects when starting with a new app...

I'm sure there are a bunch of us that would like to add/modify Plugins, who have the capability, but don't know ktorrent specifics, so maybe a sticky on Plugin development would be nice???

Thanks,
Sam


Maybe I should write a plugin development guide.
chr1syr
Registered Member
Posts
11
Karma
0

Fri Jul 25, 2008 9:08 pm
Hi, Im working with a really old version of ktorrent as I dont have new kde libs etc. These are the steps that I took to duplicate upnp as upnp2.
get ktorrent-2.0.3+dfsg1
copy upnp to upnp2
sed source files in upnp2 to replace all upnp with upnp2
script to rename all filenames with upnp to upnp2
edit plugins/Makefile.am so SUBDIRS uncludes upnp2
edit configure.in so it includes AC_CONFIG_FILES([ plugins/upnp2/Makefile ])
autoremake
configure
admin/am_edit (to patch makefiles with moc)
make
make install
ktorrent
hopefully have upnp2 as plugin

if you want the icon to show up you have to provide an icon file in apps/ktorrent and add the icon to the make system using automake or just hack the makefile
MoDaX
Registered Member
Posts
241
Karma
0
OS

Sat Jul 26, 2008 9:43 pm
chr1syr wrote:Hi, Im working with a really old version of ktorrent as I dont have new kde libs etc. These are the steps that I took to duplicate

KDE in Debian etch (4.0) is enough to compile & run 2.2.7. There is the etch backport of 2.2.6 available at:

deb http://alioth.debian.org/~modax-guest/ktorrent-etch/ ./


Bookmarks



Who is online

Registered users: Bing [Bot], Google [Bot], Yahoo [Bot]