summaryrefslogtreecommitdiff
path: root/CMakeLists.txt
blob: bf3ca8a78848b793ff8fa6d57118cb511d23b1de (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
cmake_minimum_required(VERSION 3.13)
project(kalmia)

option(KALMIA_BUILD_TESTS "Build the tests" ON)

add_library(kalmia STATIC)
target_include_directories(kalmia PUBLIC include)
if (UNIX)
	set_target_properties(
		kalmia PROPERTIES
		C_STANDARD 90
		CMAKE_C_FLAGS "-Wall -Wextra -Werror -Wfatal-errors -Wpedantic"
	)
endif()

if (KALMIA_BUILD_TESTS)
	add_executable(kalmia-tests)
	target_link_libraries(kalmia-tests kalmia)
endif()

add_subdirectory(${CMAKE_CURRENT_LIST_DIR}/src)