include_directories(
    ${CMAKE_SOURCE_DIR}/src # For lib header
    ${CMAKE_CURRENT_BINARY_DIR}
    )

set(example_LIBRARIES
    ${QT_QTGUI_LIBRARIES}
    ${QT_QTCORE_LIBRARIES}
    indicate-qt
    ${INDICATE_LIBRARIES}
    )

add_definitions(-DSOURCE_DIR=\"${CMAKE_CURRENT_SOURCE_DIR}\")

# qim-client
set(qim_client_SRCS qim-client.cpp)
qt4_automoc(${qim_client_SRCS})

add_executable(qim-client ${qim_client_SRCS})

target_link_libraries(qim-client
    ${example_LIBRARIES}
    )

# qlisten-and-print
set(qlisten_and_print_SRCS qlisten-and-print.cpp)
qt4_automoc(${qlisten_and_print_SRCS})

add_executable(qlisten-and-print ${qlisten_and_print_SRCS})

target_link_libraries(qlisten-and-print
    ${example_LIBRARIES}
    )

# qservercount
set(qservercount_SRCS qservercount.cpp)
qt4_automoc(${qservercount_SRCS})

add_executable(qservercount ${qservercount_SRCS})

target_link_libraries(qservercount
    ${example_LIBRARIES}
    )
