Skip to content

Commit b1d493d

Browse files
authored
Merge pull request #425 from drmpeg/submodule-check
cmake: Detect if cpu_features submodule is present.
2 parents 951abda + 1ea34ed commit b1d493d

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

CMakeLists.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,9 @@ else()
122122
option(VOLK_CPU_FEATURES "Volk uses cpu_features" OFF)
123123
endif()
124124
if (VOLK_CPU_FEATURES)
125+
if(NOT EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/cpu_features/CMakeLists.txt" )
126+
message(FATAL_ERROR "cpu_features/CMakeLists.txt not found. Did you forget to git clone recursively?\nFix with: git submodule update --init")
127+
endif()
125128
message(STATUS "Building Volk with cpu_features")
126129
set(BUILD_PIC ON CACHE BOOL
127130
"Build cpu_features with Position Independent Code (PIC)."

0 commit comments

Comments
 (0)