-
-
Notifications
You must be signed in to change notification settings - Fork 194
/
Copy pathCMakeLists.txt
30 lines (23 loc) · 843 Bytes
/
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
cmake_minimum_required(VERSION 3.16)
project(ImHex-Patterns)
option(IMHEX_PATTERNS_ENABLE_UNIT_TESTS "Enable building unit tests for ImHex-Patterns" OFF)
# if enabled, add a unit_test custom target for all the unit tests to be registered against
if(IMHEX_PATTERNS_ENABLE_UNIT_TESTS)
if(NOT TARGET unit_tests)
enable_testing()
add_custom_target(unit_tests)
endif()
endif()
# If this has been manually cloned into another project, libpl may already have been set up
if(NOT TARGET libpl)
include(FetchContent)
FetchContent_Declare(
pattern_language
GIT_REPOSITORY https://github.com/WerWolv/PatternLanguage
GIT_TAG master
)
FetchContent_MakeAvailable(pattern_language)
endif()
if(IMHEX_PATTERNS_ENABLE_UNIT_TESTS)
add_subdirectory(tests)
endif()