-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
88 lines (73 loc) · 1.36 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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
# cmake_minimum_required(VERSION <specify CMake version here>)
project(mymalloc)
set(CMAKE_CXX_STANDARD 14)
set(
mymalloc_src
heap.h
heap.cpp
bitmap.h
consts.h
span.cpp
central.cpp
cache.cpp
amalloc.h
)
add_executable(
mymalloc
main.cpp
${mymalloc_src}
)
add_executable(
mallocTest
test/mallocTest.cpp
${mymalloc_src}
)
add_executable(
freeTest
test/freeTest.cpp
${mymalloc_src}
)
add_executable(
mapTest
test/mapTest.cpp
)
add_executable(
threadTest
test/threadTest.cpp
)
target_link_libraries(
threadTest
pthread
)
add_executable(
threadMallocTest
test/threadMallocTest.cpp
${mymalloc_src}
)
target_link_libraries(
threadMallocTest
pthread
)
add_executable(
cpuTest
test/cpuTest.cpp
)
target_link_libraries(
cpuTest
pthread
)
add_executable(
redefineTest
test/redefine/redefineTest.cpp
test/redefine/redefine.h
)
add_executable(
staticTest
test/staticTest.cpp
${mymalloc_src}
)
add_executable(
overrideTest
test/new_delete/override.cpp
${mymalloc_src}
)