-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCMakeLists.txt
54 lines (42 loc) · 1.42 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
###################################################################################################
##
## Information about the project
##
###################################################################################################
cmake_minimum_required(VERSION 3.16)
set(PROJECT_NAME libc)
project(${PROJECT_NAME} VERSION 0.0.1 LANGUAGES C)
###################################################################################################
##
## Compilation options
##
###################################################################################################
add_compile_options(
-Werror
-Wall
-Wextra
-Wpedantic
-Wcast-align
-Wcast-qual
-Wconversion
-Wfloat-equal
-Wredundant-decls
-Wsign-conversion
)
###################################################################################################
##
## Project options
##
###################################################################################################
include_directories(include tests)
set(SOURCES
src/main.c
src/string.c
tests/tests.c src/memory.c src/garbage_collector.c)
set(HEADERS
include/string.h
tests/tests.h include/memory.h include/garbage_collector.h)
add_executable(${PROJECT_NAME} ${SOURCES} ${HEADERS})
include (CTest)
add_test(valgrind_test ${PROJECT_NAME})
add_subdirectory(smart_pointers)