cmake_minimum_required(VERSION 3.3)

project(enyx-net-hw-latency-test
    VERSION
        1.0.0
    LANGUAGES
        C CXX)

set(CMAKE_CXX_STANDARD 11)

find_package(enyx-cores REQUIRED)
find_package(Threads REQUIRED)

include(GNUInstallDirs)

add_executable(
    enyx-net-hw-tcp-latency-test

    tcp.cpp)

target_link_libraries(
    enyx-net-hw-tcp-latency-test

    PRIVATE
        Boost::program_options
        enyx-cores-tools
        enyx-cores
        enyx-hw-c
        Threads::Threads)

add_executable(
    enyx-net-hw-udp-latency-test

    udp.cpp)

target_link_libraries(
    enyx-net-hw-udp-latency-test

    PRIVATE
        Boost::program_options
        enyx-cores-tools
        enyx-cores
        enyx-hw-c
        Threads::Threads)

install(
    TARGETS
        enyx-net-hw-tcp-latency-test
        enyx-net-hw-udp-latency-test
    DESTINATION
        ${CMAKE_INSTALL_BINDIR})
