CMakeLists.txt 809 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. # Set the project name
  2. project (gateway-scheduler)
  3. # CMAKE_SOURCE_DIR path to CMakeLists.txt directory
  4. set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_SOURCE_DIR}/deploy/bin)
  5. set(INCLUDE_SUBDIRECTORIES
  6. ${CMAKE_SOURCE_DIR}/include
  7. ${CMAKE_SOURCE_DIR}/library/include
  8. ${CMAKE_SOURCE_DIR}/modules
  9. ${CMAKE_SOURCE_DIR}/deploy/library
  10. )
  11. include_directories(${INCLUDE_SUBDIRECTORIES})
  12. file(GLOB_RECURSE SRC_FILES src/*.cpp)
  13. link_directories(${CMAKE_SOURCE_DIR}/library/lib)
  14. link_libraries(
  15. gateway-basic
  16. sqlite3
  17. boost_filesystem
  18. modbus
  19. pthread
  20. paho-mqttpp3
  21. paho-mqtt3as
  22. iec61850
  23. )
  24. # Add an executable
  25. add_executable(${PROJECT_NAME} ${SRC_FILES})
  26. target_link_libraries(${PROJECT_NAME} PUBLIC gateway-basic)