File tree Expand file tree Collapse file tree 2 files changed +42
-2
lines changed Expand file tree Collapse file tree 2 files changed +42
-2
lines changed Original file line number Diff line number Diff line change @@ -24,6 +24,9 @@ project(
24
24
"Session-based abstractions for Beast + URL parsing and pct-coding"
25
25
)
26
26
27
+ set (CMAKE_FILES ${CMAKE_CURRENT_SOURCE_DIR} /cmake )
28
+ include (${CMAKE_FILES} /certify.cmake )
29
+
27
30
find_package (
28
31
Boost ${foxy_minimum_boost_version}
29
32
REQUIRED
@@ -163,8 +166,14 @@ add_library(
163
166
target_include_directories (test_utils PUBLIC test /include )
164
167
target_link_libraries (test_utils PUBLIC foxy )
165
168
166
- option (BUILD_TESTING "Build Foxy Testsuite" OFF )
167
- if (BUILD_TESTING )
169
+ cmake_dependent_option (FOXY_BUILD_TESTING
170
+ "Build the C++ unit tests."
171
+ ON
172
+ "BUILD_TESTING"
173
+ OFF
174
+ )
175
+
176
+ if (FOXY_BUILD_TESTING )
168
177
include (CTest )
169
178
170
179
find_package (Catch2 CONFIG REQUIRED )
@@ -248,3 +257,7 @@ if (FOXY_FUZZ)
248
257
target_link_options (uri-parser PRIVATE "-fsanitize=fuzzer" )
249
258
endif ()
250
259
260
+ install (
261
+ TARGETS foxy
262
+ EXPORT ${PROJECT_NAME} Targets
263
+ )
Original file line number Diff line number Diff line change
1
+ cmake_minimum_required (VERSION 3.11 )
2
+
3
+ include (FetchContent )
4
+
5
+ if (${CMAKE_VERSION} VERSION_GREATER_EQUAL "3.24" )
6
+ # Affects robustness of timestamp checking on FetchContent dependencies.
7
+ cmake_policy (SET CMP0135 NEW )
8
+ endif ()
9
+
10
+
11
+ FetchContent_Declare (certify
12
+ GIT_REPOSITORY https://github.com/cwaldren-ld/certify.git
13
+ GIT_TAG 8fc3024f97ffcc7442e30e1fe6ddff54b45e35d6
14
+ )
15
+
16
+ # The tests in certify don't compile.
17
+ set (PREVIOUS_BUILD_TESTING ${BUILD_TESTING} )
18
+ set (BUILD_TESTING OFF )
19
+
20
+ FetchContent_MakeAvailable (certify )
21
+
22
+ set (BUILD_TESTING ${PREVIOUS_BUILD_TESTING} )
23
+
24
+ install (
25
+ TARGETS core
26
+ EXPORT ${PROJECT_NAME} Targets
27
+ )
You can’t perform that action at this time.
0 commit comments