Skip to content

Commit d5ca7f8

Browse files
Илья Ракитинgittiver
authored andcommitted
CROW_GENERATE_SBOM also need CPM. Fix CMakeLists.txt
1 parent 48c4ef1 commit d5ca7f8

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

CMakeLists.txt

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,10 @@ option(CROW_RETURNS_OK_ON_HTTP_OPTIONS_REQUEST
5858
option(CROW_ENABLE_SSL "Enable Crow's SSL feature for supporting https" OFF)
5959
option(CROW_ENABLE_COMPRESSION "Enable Crow's Compression feature for supporting compressed http content" OFF)
6060

61+
if(CROW_GENERATE_SBOM OR CROW_BUILD_TESTS)
62+
include(${CMAKE_CURRENT_SOURCE_DIR}/cmake/CPM.cmake)
63+
endif ()
64+
6165
if(CROW_GENERATE_SBOM)
6266
CPMAddPackage(
6367
NAME cmake-sbom
@@ -253,7 +257,6 @@ endif()
253257

254258
# Tests
255259
if(CROW_BUILD_TESTS)
256-
include(${CMAKE_CURRENT_SOURCE_DIR}/cmake/CPM.cmake)
257260

258261
add_subdirectory(tests)
259262
enable_testing()

0 commit comments

Comments
 (0)