diff --git a/CMakeLists.txt b/CMakeLists.txt index 87f5984c1..a49c60ec3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -148,6 +148,7 @@ cmake_dependent_option(WITH_NODE_TEST_RTT "Build with test_rtt node-type" cmake_dependent_option(WITH_NODE_ULDAQ "Build with uldaq node-type" ON "LIBULDAQ_FOUND" OFF) cmake_dependent_option(WITH_NODE_WEBSOCKET "Build with websocket node-type" ON "WITH_WEB; LIBWEBSOCKETS_FOUND" OFF) cmake_dependent_option(WITH_NODE_ZEROMQ "Build with zeromq node-type" ON "LIBZMQ_FOUND" OFF) +cmake_dependent_option(WITH_NODE_ETHERCAT "Build with ethercat node-type" ON "ETHERLAB_FOUND" OFF) cmake_dependent_option(WITH_NODE_EXAMPLE "Build with example node-type" ON "" OFF) # Add more build configurations diff --git a/lib/nodes/CMakeLists.txt b/lib/nodes/CMakeLists.txt index a2937d13f..673a98a27 100644 --- a/lib/nodes/CMakeLists.txt +++ b/lib/nodes/CMakeLists.txt @@ -162,7 +162,7 @@ if(WITH_NODE_EXAMPLE) endif() # Enable Ethercat support -if(ETHERLAB_FOUND AND WITH_IO) +if(WITH_NODE_ETHERCAT) list(APPEND NODE_SRC ethercat.cpp) list(APPEND INCLUDE_DIRS ${ETHERLAB_INCLUDE_DIRS}) list(APPEND LIBRARIES ${ETHERLAB_LIBRARIES})