* Don't build the kdevplatform smoke lib by default
[kdebindings.git] / python / krosspython / CMakeLists.txt
blob70b5f7e25c61d1d0226f3b64b325a192d2ae7615
1 PROJECT(KROSSPYTHON)
3 find_package(PythonLibrary REQUIRED)
4 include(PythonMacros)
6 include_directories(
7     ${PYTHON_INCLUDE_PATH}
8     ${QT_INCLUDE_DIR}
9     ${QT_QT_INCLUDE_DIR}
10     ${QT_QTCORE_INCLUDE_DIR}
11     ${QT_QTGUI_INCLUDE_DIR}
12     #${QT_QTNETWORK_INCLUDE_DIR}
13     #${QT_QTXML_INCLUDE_DIR}
14     ${KDE4_INCLUDE_DIR}
15     ${KDE4_INCLUDE_DIR}/kross
18 set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${KDE4_ENABLE_EXCEPTIONS}")
20 ########### next target ###############
22 add_subdirectory( cxx )
24 set(libkrosspythoncxx_SRCS
25     ${CMAKE_SOURCE_DIR}/python/krosspython/cxx/cxxsupport.cxx
26     ${CMAKE_SOURCE_DIR}/python/krosspython/cxx/cxx_extensions.cxx
27     ${CMAKE_SOURCE_DIR}/python/krosspython/cxx/cxxextensions.c
28     ${CMAKE_SOURCE_DIR}/python/krosspython/cxx/IndirectPythonInterface.cxx
31 ########### next target ###############
33 set(krosspython_PART_SRCS ${libkrosspythoncxx_SRCS}
34    pythonvariant.cpp
35    pythonextension.cpp
36    pythonmodule.cpp
37    pythonscript.cpp
38    pythoninterpreter.cpp
39    pythonobject.cpp
42 kde4_add_plugin(krosspython ${krosspython_PART_SRCS})
44 # -ldl seems to be needed (on Linux at least).
45 # see http://lists.kde.org/?l=koffice-devel&m=116333261328694&w=2
46 # and http://websvn.kde.org/branches/work/kwin_composite/CMakeLists.txt?rev=603677&r1=603384&r2=603677
47 target_link_libraries(krosspython ${QT_QTCORE_LIBRARY} ${QT_QTGUI_LIBRARY} ${KDE4_KPTY_LIBS} ${KDE4_KROSSCORE_LIBS} ${PYTHON_LIBRARIES} ${CMAKE_DL_LIBS})
49 install(TARGETS krosspython  DESTINATION ${PLUGIN_INSTALL_DIR})