include_directories(
  ${CMAKE_SOURCE_DIR}/akonadi
  ${QT_QTDBUS_INCLUDE_DIR}
)

set( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${KDE4_ENABLE_EXCEPTIONS}" )


########### next target ###############

set( kabcresource_SRCS
  kabcresource.cpp
  kresourceassistant.cpp
)

install( FILES kabcresource.desktop DESTINATION "${CMAKE_INSTALL_PREFIX}/share/akonadi/agents" )


kde4_add_executable(akonadi_kabc_resource RUN_UNINSTALLED ${kabcresource_SRCS})

target_link_libraries(akonadi_kabc_resource ${KDE4_AKONADI_LIBS} ${QT_QTCORE_LIBRARY} ${QT_QTDBUS_LIBRARY} ${KDE4_KDECORE_LIBS} ${KDE4_KABC_LIBS} ${KDE4_KIO_LIBS} kdepim)

install(TARGETS akonadi_kabc_resource ${INSTALL_TARGETS_DEFAULT_ARGS})
