-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
54 lines (44 loc) · 1.34 KB
/
CMakeLists.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
cmake_minimum_required(VERSION 3.16.3)
project(graph)
if (${CMAKE_VERSION} VERSION_GREATER "3.23.2")
cmake_policy(SET CMP0135 NEW)
endif()
set(CMAKE_CXX_STANDARD 14)
include(FetchContent)
FetchContent_Declare(
googletest
URL https://github.com/google/googletest/archive/5376968f6948923e2411081fd9372e71a59d8e77.zip)
# For Windows: Prevent overriding the parent project's compiler/linker settings
set(gtest_force_shared_crt ON CACHE BOOL "" FORCE)
FetchContent_MakeAvailable(googletest)
set(PROJECT_HEADERS
src/DGraph.h
src/implementation/DynamicPQ.hpp
src/implementation/Edge.hpp
src/implementation/Graph.h
src/implementation/Path.hpp
src/implementation/Vertex.hpp
src/UGraph.h)
set(PROJECT_SOURCES
src/DGraph.cpp
src/implementation/Graph.cpp
src/UGraph.cpp)
set(PROJECT_TESTS
tests/bfsTest.cpp
tests/dfsTest.cpp
tests/dijkstraTest.cpp
tests/dynamicPQTest.cpp
tests/initializationTest.cpp
tests/manipulationTest.cpp
tests/maximumFlowTest.cpp
tests/mstTest.cpp
tests/TestGraphs.h
tests/TestGraphs.cpp)
add_executable(graph
${PROJECT_HEADERS}
${PROJECT_SOURCES}
${PROJECT_TESTS})
target_link_libraries(graph
gtest
gtest_main)
enable_testing()