CMakeLists.txt 829 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  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. libloragw.a
  24. )
  25. # Add an executable
  26. add_executable(${PROJECT_NAME} ${SRC_FILES})
  27. target_link_libraries(${PROJECT_NAME} PUBLIC gateway-basic)