Am Sonntag 09 September 2007 18:53:00 schrieb Matt Rogers:
> >
> > change this to:
> > link_directories( $KDE4_LIB_DIR ... ${CMAKE_CURRENT_BINARY_DIR}
> > kopete )
> > this will add a -lkopete to the link command
>
> Yes, I suppose that's what it will do, but that's not the right way
> to do it. link_directories is for specifying -L options to the
> compiler, not -l options (there is a difference)
>
> > btw, I dont think all those link directories are necessary
>
> no, they're not, in fact, ${KDE_LIB_DIR}/kde4 is wrong. You should
> remove that line. You shouldn't be linking to things in $
> {KDE_LIB_DIR}/kde4
>

OK... Removed ${KDE_LIB_DIR}/kde4

>
> You're missing an -lkopete line in your line command.
> You should have a "target_link_libraries" function in your
> CMakeLists.txt file. Add a kopete entry to that list. It'll probably
> end up looking something like:
>
> target_link_libraries( <target-name> <other-libs> kopete )
>
> where <target-name> and <other-libs> is the name of the target and
> the additional libraries you're also linking to, respectively.
>
> Hope this helps

Yes, it does! Thank you! Had to add kopete and kdeui (For some popups).

Anyway... There is another problem now:
kopete-otr consists of three libraries: kopete_otr (the plugin itself), 
kcm_kopete_otr (the configuration module) and libkotr (Interface between the 
plugin and libotr).
kopete_otr and kcm_kopete_otr link against libkotr to communicate with the 
libotr.
For example to store the per-user encryption policy I use:
MetaContact->pluginData(OTRPlugin::plugin(), "otr_policy");
libkotr now needs to determine the policy so it needs to call 
OTRPlugin::plugin(). But for this it would need to be linked to kopete_otr. 
This is kind of a circular linkage where automake works but cmake complains 
about this.

What would be the right way to have access to OTRPlugin::plugin() in libkotr?
AFAIK there would be a way to get it through KopetePluginManager but this 
class is not accessable for external plugins since kopetepluginmanager.h is 
in noinstall...

Michael

Attachment: signature.asc
Description: This is a digitally signed message part.

_______________________________________________
kopete-devel mailing list
[email protected]
https://mail.kde.org/mailman/listinfo/kopete-devel

Reply via email to