Skip to content

Commit 86680e8

Browse files
committed
Skip rocksdb plugin if sources can not be fetched
Either we are building from a source package, in which case all sources should be present, or we are building from a repository. The repository needs to fetch the rocksdb submodule before building rocksdb.
1 parent 4653b6e commit 86680e8

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

storage/rocksdb/CMakeLists.txt

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,10 @@
11
# TODO: Copyrights
2+
3+
MACRO(SKIP_ROCKSDB_PLUGIN msg)
4+
MESSAGE_ONCE(SKIP_ROCKSDB_PLUGIN "Can't build rocksdb engine - ${msg}")
5+
RETURN()
6+
ENDMACRO()
7+
28
IF(NOT EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/rocksdb/Makefile AND GIT_EXECUTABLE)
39
EXECUTE_PROCESS(COMMAND "${GIT_EXECUTABLE}" submodule init
410
WORKING_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}")
@@ -7,14 +13,9 @@ IF(NOT EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/rocksdb/Makefile AND GIT_EXECUTABLE)
713
ENDIF()
814

915
IF (NOT EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/rocksdb/Makefile")
10-
MESSAGE(SEND_ERROR "Missing Makefile in rocksdb directory. Try \"git submodule update\".")
16+
SKIP_ROCKSDB_PLUGIN("Missing Makefile in rocksdb directory. Try \"git submodule update\".")
1117
ENDIF()
1218

13-
MACRO(SKIP_ROCKSDB_PLUGIN msg)
14-
MESSAGE_ONCE(SKIP_ROCKSDB_PLUGIN "Can't build rocksdb engine - ${msg}")
15-
RETURN()
16-
ENDMACRO()
17-
1819
# We've had our builders hang during the build process. This prevents MariaRocks
1920
# to be built on 32 bit intel OS kernels.
2021
IF(CMAKE_SYSTEM_PROCESSOR MATCHES "i[36]86")

0 commit comments

Comments
 (0)