-
Notifications
You must be signed in to change notification settings - Fork 1
/
CMakeLists.txt
26 lines (18 loc) · 1.13 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
# CMake configuration
cmake_minimum_required (VERSION 2.8.12)
enable_language(C)
set (CMAKE_C_STANDARD 11)
set (CMAKE_C_STANDARD_REQUIRED)
set (PROJECT_NAME mud)
set (CMAKE_C_CLANG_TIDY "clang-tidy" "-checks=clang-analyzer-*, concurrency-*, misc-*, performance-*, portability-*, readability-*, -clang-analyzer-security.insecureAPI.DeprecatedOrUnsafeBufferHandling, -misc-unused-parameters, -clang-diagnostic-unused-parameter, -readability-non-const-parameter, -readability-magic-numbers" "-header-filter=*")
# "-warnings-as-errors=*, -readability-non-const-parameter, -misc-unused-parameters, -clang-analyzer-security.insecureAPI.DeprecatedOrUnsafeBufferHandling"
project (${PROJECT_NAME} C)
find_package(Lua51 REQUIRED)
# Build configuration
add_definitions("-Wall -pedantic")
include_directories(${PROJECT_SOURCE_DIR}/include ${LUA_INCLUDE_DIR})
# Executable configuration
file(GLOB_RECURSE SRC_FILES RELATIVE ${PROJECT_SOURCE_DIR} ${PROJECT_SOURCE_DIR}/src/*.c)
add_executable(${PROJECT_NAME} ${SRC_FILES})
target_link_libraries(${PROJECT_NAME} uuid sqlite3 ssl crypto ${LUA_LIBRARIES} ${CMAKE_DL_LIBS})
install(TARGETS ${PROJECT_NAME} DESTINATION ..)