1 Star 0 Fork 301

宋卫兵/oceanbase-show

forked from ShawnYan/oceanbase-show 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
CMakeLists.txt 2.09 KB
一键复制 编辑 原始数据 按行查看 历史
cmake_minimum_required(VERSION 3.20.0)
include(cmake/Utils.cmake)
include(cmake/Env.cmake)
project("OceanBase CE"
VERSION 3.1.2
DESCRIPTION "OceanBase distributed database system"
HOMEPAGE_URL "https://open.oceanbase.com/"
LANGUAGES CXX C ASM)
ob_define(WITH_OSS OFF)
ob_define(ENABLE_FATAL_ERROR_HANG OFF)
if(ENABLE_DEBUG_LOG)
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DENABLE_DEBUG_LOG")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DENABLE_DEBUG_LOG")
endif()
if(WITH_OSS)
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D_WITH_OSS")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -D_WITH_OSS")
endif()
if(OB_USE_ASAN)
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DOB_USE_ASAN")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DOB_USE_ASAN")
endif()
if (ENABLE_FATAL_ERROR_HANG)
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DFATAL_ERROR_HANG")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DFATAL_ERROR_HANG")
endif()
message(STATUS "This is BINARY dir " ${PROJECT_BINARY_DIR})
message(STATUS "This is SOURCE dir " ${PROJECT_SOURCE_DIR})
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
add_subdirectory(deps/easy)
add_subdirectory(deps/oblib)
add_subdirectory(src)
include(CMakeDependentOption)
# OB_BUILD_RPM => include tools and build them.
# otherwise => include tools but don't build them.
option(OB_INCLUDE_TOOLS "" ON)
cmake_dependent_option(
OB_BUILD_TOOLS "Build tools" ON
"OB_BUILD_RPM" OFF)
# OB_BUILD_RPM => don't include unittest or build them.
# otherwise => include unittest but don't build them.
cmake_dependent_option(
OB_INCLUDE_UNITTEST "Include unittest" ON
"NOT OB_BUILD_RPM" OFF)
option(OB_BUILD_UNITTEST "" OFF)
# OB_BUILD_RPM => don't include test or build them.
# otherwise => include test but don't build them.
cmake_dependent_option(
OB_INCLUDE_TEST "Include test" ON
"NOT OB_BUILD_RPM" OFF)
option(OB_BUILD_TEST "" OFF)
include(CTest)
if (OB_BUILD_UNITTEST)
add_subdirectory(unittest)
elseif(OB_INCLUDE_UNITTEST)
add_subdirectory(unittest EXCLUDE_FROM_ALL)
endif()
if (OB_BUILD_TOOLS)
add_subdirectory(tools)
elseif (OB_INCLUDE_TOOLS)
add_subdirectory(tools EXCLUDE_FROM_ALL)
endif()
include(cmake/RPM.cmake)
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
C++
1
https://gitee.com/songweibing/oceanbase-show.git
git@gitee.com:songweibing/oceanbase-show.git
songweibing
oceanbase-show
oceanbase-show
master

搜索帮助

0d507c66 1850385 C8b1a773 1850385