Advertisement
Nuke29

CMakeLists.txt

Oct 5th, 2022 (edited)
1,184
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
CMake 0.64 KB | Source Code | 0 0
  1. cmake_minimum_required(VERSION 3.5)
  2.  
  3. project(intersect_segments LANGUAGES CXX)
  4.  
  5. set(CMAKE_CXX_STANDARD 17)
  6. set(CMAKE_CXX_STANDARD_REQUIRED ON)
  7.  
  8. add_library(segmentslib
  9.     src/segments_lib/segments.cpp
  10.     src/segments_lib/segments.h)
  11. include_directories(${CMAKE_SOURCE_DIR}/src/segments_lib)
  12. link_directories(${CMAKE_SOURCE_DIR}/src/segments_lib)
  13.  
  14. add_executable(intersect_segments src/main.cpp)
  15.  
  16.  
  17. set_target_properties(intersect_segments PROPERTIES
  18.     CXX_STANDARD 17
  19.     CXX_STANDARD_REQUIRED YES
  20.     CXX_EXTENSIONS YES)
  21.  
  22. add_dependencies(intersect_segments segmentslib)
  23. target_link_libraries(intersect_segments segmentslib)
  24.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement