[Kde-games-devel] Using libkeclarative

Viranch Mehta viranch.mehta at gmail.com
Mon Jun 11 23:04:27 UTC 2012


Hi,

I want to use kdeclarative for my qml port of kbreakout, mainly for
translations. But cmake doesn't find the library.

I added:

kbreakout/CMakeLists.txt:
find_package(KDeclarative REQUIRED)

kbreakout/src/CMakeLists.txt:
include_directories(${KDECLARATIVE_INCLUDE_DIR})
target_link_libraries(kbreakout ..... ${KDECLARATIVE_LIBRARIES})

I have kbreakout/src/canvaswidget.cpp that uses KDeclarative as follows:

#include <kdeclarative.h>
KDeclarative kdeclarative;
kdeclarative.setDeclarativeEngine(engine());
kdeclarative.initialize();
kdeclarative.setupBindings();

I get this error while compiling: http://paste.kde.org/497690/

I checked my $KDEDIR/share/apps/cmake/modules directory and it doesn't
have any FindKDeclarative.cmake (which I think should be there).

If any of it matters:
I don't have kdelibs/runtime/workspace compiled from source, using
kde 4.8.4 distro packages. I've compiled libkdegames and libkmahjongg
from latest SVN.

Can someone help me out?

Thanks,
Viranch
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-games-devel/attachments/20120612/036e3c6b/attachment.html>


More information about the kde-games-devel mailing list