project(system_monitor)

# We add our source code here
set(cpu_mon_SRCS cpu_monitor.cpp)
set(mem_mon_SRCS mem_monitor.cpp)

add_definitions (${QT_DEFINITIONS} ${KDE4_DEFINITIONS})
include_directories(${KDE4_INCLUDES})
 
# Now make sure all files get to the right place
kde4_add_plugin(plasma_engine_cpumonitor ${cpu_mon_SRCS})
kde4_add_plugin(plasma_engine_memmonitor ${mem_mon_SRCS})

target_link_libraries(plasma_engine_cpumonitor
                      ${PLASMA_LIBS} ${KDE4_SOLID_LIBS} ${KDE4_KDEUI_LIBS})
target_link_libraries(plasma_engine_memmonitor ${PLASMA_LIBS} ${KDE4_KDEUI_LIBS})
 
install(TARGETS plasma_engine_cpumonitor
        DESTINATION ${PLUGIN_INSTALL_DIR})
 
install(TARGETS plasma_engine_memmonitor
        DESTINATION ${PLUGIN_INSTALL_DIR})
 
install(FILES plasma-dataengine-cpu_monitor.desktop
        DESTINATION ${SERVICES_INSTALL_DIR})

install(FILES plasma-dataengine-mem_monitor.desktop
        DESTINATION ${SERVICES_INSTALL_DIR})
