代码拉取完成,页面将自动刷新
同步操作将从 Gitee 极速下载/manticoresearch 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
cmake_minimum_required ( VERSION 3.17 )
# this file included by cpack config in order to detect if configured and build version are the same
# guess version strings from current git repo
function ( guess_from_git )
if (NOT EXISTS "${MANTICORE_SOURCE_DIR}/.git")
return ()
endif ()
find_package ( Git QUIET )
if (NOT GIT_FOUND)
return ()
endif ()
# extract short has as CHECK_GIT_COMMIT_ID
execute_process ( COMMAND "${GIT_EXECUTABLE}" log -1 --format=%h
WORKING_DIRECTORY "${MANTICORE_SOURCE_DIR}"
RESULT_VARIABLE res
OUTPUT_VARIABLE CHECK_GIT_COMMIT_ID
ERROR_QUIET
OUTPUT_STRIP_TRAILING_WHITESPACE )
set ( CHECK_GIT_COMMIT_ID "${CHECK_GIT_COMMIT_ID}" PARENT_SCOPE )
endfunction ()
# guess version strings from template header file (git archive mark it there)
function ( extract_from_git_slug HEADER )
if (EXISTS "${HEADER}")
FILE ( STRINGS "${HEADER}" _CONTENT )
foreach (LINE ${_CONTENT})
# match definitions like - // GIT_*_ID VALUE
if ("${LINE}" MATCHES "^//[ \t]+(GIT_.*_ID)[ \t]\"(.*)\"")
set ( ${CMAKE_MATCH_1} "${CMAKE_MATCH_2}" )
endif ()
endforeach ()
if (GIT_COMMIT_ID STREQUAL "$Format:%h$")
return () # no slug
endif ()
# commit id
set ( CHECK_GIT_COMMIT_ID "${GIT_COMMIT_ID}" PARENT_SCOPE )
endif ()
endfunction ()
# function definitions finished, execution starts from here
##################################
# first try to use binary git
guess_from_git ()
# 2-nd try - if we build from git archive. Correct hash and date provided then, but no branch
if (NOT CHECK_GIT_COMMIT_ID)
extract_from_git_slug ( "${MANTICORE_SOURCE_DIR}/src/sphinxversion.h.in" )
endif ()
if (NOT CHECK_GIT_COMMIT_ID)
set ( CHECK_GIT_COMMIT_ID "DEADBEEF" )
endif ()
if (NOT CHECK_GIT_COMMIT_ID STREQUAL "${CONFIGURED_GIT_COMMIT_ID}")
message ( FATAL_ERROR "Current commit ${CHECK_GIT_COMMIT_ID} is differs from stored ${CONFIGURED_GIT_COMMIT_ID}. Run 'cmake .' in build dir to fix" )
endif ()
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。