aboutsummaryrefslogtreecommitdiffstats
path: root/nihil.monad/CMakeLists.txt
blob: b0fa0951de50e87d0416737631d7c3ffcad32904 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# This source code is released into the public domain.

add_library(nihil.monad STATIC)
target_link_libraries(nihil.monad PRIVATE nihil.error)
target_sources(nihil.monad
	PUBLIC FILE_SET modules TYPE CXX_MODULES FILES
	monad.ccm
)

if(NIHIL_TESTS)
	enable_testing()

	add_executable(nihil.monad.test test.cc)
	target_link_libraries(nihil.monad.test PRIVATE
		nihil.monad
		Catch2::Catch2WithMain
	)

	find_package(Catch2 REQUIRED)

	include(CTest)
	include(Catch)
	catch_discover_tests(nihil.monad.test)
endif()