mdbx-cmake: add MDBX_FORCE_BUILD_AS_MAIN_PROJECT.

This commit is contained in:
Leonid Yuriev 2021-11-16 17:57:54 +03:00 committed by Леонид Юрьев (Leonid Yuriev)
parent ff26d30362
commit 86c735637e

View File

@ -93,6 +93,10 @@ else()
endif()
if(DEFINED PROJECT_NAME)
option(MDBX_FORCE_BUILD_AS_MAIN_PROJECT "Force libmdbx to full control build options even it added as a subdirectory to your project." OFF)
endif()
if(DEFINED PROJECT_NAME AND NOT MDBX_FORCE_BUILD_AS_MAIN_PROJECT)
set(SUBPROJECT ON)
set(NOT_SUBPROJECT OFF)
if(NOT MDBX_AMALGAMATED_SOURCE AND NOT DEFINED BUILD_TESTING)