Creepinson

Untitled

Jul 31st, 2021
1,044
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. cmake_minimum_required(VERSION "3.10")
  2.  
  3. # set the project name
  4. project("Chatlab")
  5.  
  6. # add src files
  7. file(GLOB SOURCES ${PROJECT_SOURCE_DIR}/src/*.cpp)
  8. file(GLOB HEADERS ${PROJECT_SOURCE_DIR}/src/include/*.h)
  9.  
  10. # add the executable
  11. add_executable(${PROJECT_NAME} ${SOURCES})
  12. target_include_directories(${PROJECT_NAME} PUBLIC ${PROJECT_SOURCE_DIR}/src/include)
  13.  
  14. # Glfw
  15. add_subdirectory("libs/glfw")
  16. target_link_libraries(${PROJECT_NAME} "glfw")
  17.  
  18. # Glew
  19. add_definitions(-DGLEW_STATIC)
  20. add_subdirectory("libs/glew")
  21.  
  22. # YAML parser
  23. add_subdirectory("libs/yaml")
  24. target_link_libraries(${PROJECT_NAME} "yaml-cpp::yaml-cpp" "libglew_static")
RAW Paste Data