1 Star 0 Fork 2

awebc/sphinx

forked from 熊欲轻飞/sphinx 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
CMakeLists.txt 2.20 KB
一键复制 编辑 原始数据 按行查看 历史
eric1688 提交于 2015-07-22 00:43 . init
cmake_minimum_required (VERSION 2.8)
FOREACH(policy CMP0012 CMP0013 CMP0014)
IF(POLICY ${policy})
CMAKE_POLICY(SET ${policy} NEW)
ENDIF()
ENDFOREACH()
# override default options which affects windows builds
# that is necessary to change /MD to /MT, and also to set libraries on win to implicitly defined
set(CMAKE_USER_MAKE_RULES_OVERRIDE ${CMAKE_CURRENT_SOURCE_DIR}/cmake/c_flag_overrides.cmake)
set(CMAKE_USER_MAKE_RULES_OVERRIDE_CXX ${CMAKE_CURRENT_SOURCE_DIR}/cmake/cxx_flag_overrides.cmake)
PROJECT(SPHINXSEARCH)
SET(SPHINXSEARCH_CMAKE_DIR "${SPHINXSEARCH_SOURCE_DIR}/cmake")
SET(CMAKE_MODULE_PATH "${SPHINXSEARCH_SOURCE_DIR}/cmake")
SET(EXTRA_LIBRARIES "")
if (WIN32)
include (select_library_dir)
else(WIN32)
OPTION(WITH_STEMMER "compile with stemmer support" ON)
IF (WITH_STEMMER)
# check whether we have in-source libstemmer
if (EXISTS "${SPHINXSEARCH_SOURCE_DIR}/libstemmer_c/include/libstemmer.h")
add_subdirectory(libstemmer_c)
ELSE (EXISTS "${SPHINXSEARCH_SOURCE_DIR}/libstemmer_c/include/libstemmer.h")
find_package(stemmer)
ENDIF (EXISTS "${SPHINXSEARCH_SOURCE_DIR}/libstemmer_c/include/libstemmer.h")
IF (STEMMER_FOUND)
SET (EXTRA_LIBRARIES ${EXTRA_LIBRARIES} ${STEMMER_LIBRARIES})
include_directories (${STEMMER_INCLUDE_DIR})
SET (USE_LIBSTEMMER 1)
ENDIF (STEMMER_FOUND)
ENDIF (WITH_STEMMER)
endif (WIN32)
#if(CMAKE_CONFIGURATION_TYPES)
if (NOT WIN32)
# dlopen doesn't affect windows anyway
OPTION(DL_EXPAT "Load libexpat using dlopen" ON)
endif (NOT WIN32)
include (helpers)
add_subdirectory (src)
install(FILES sphinx-min.conf.dist DESTINATION etc/sphinx COMPONENT config)
install(FILES doc/sphinx.html doc/sphinx.txt DESTINATION share/doc COMPONENT doc)
set(CPACK_GENERATOR "DEB")
set(CPACK_PACKAGE_NAME "SphinxSearch")
set(CPACK_PACKAGE_VERSION_MAJOR "0")
set(CPACK_PACKAGE_VERSION_MINOR "2")
set(CPACK_PACKAGE_VERSION_PATCH "0")
#set(CPACK_DEBIAN_PACKAGE_DEPENDS "cssrobopec,libqt4-xml,libqt4-network,libqtgui4,treeupdatablereeti")
set(CPACK_PACKAGE_DESCRIPTION "Configure UExhibitor and launch missions")
set(CPACK_PACKAGE_CONTACT "Sphinx package builds <builds@sphinxsearch.com>")
#set(CPACK_DEBIAN_PACKAGE_CONTROL_EXTRA "${CMAKE_CURRENT_SOURCE_DIR}/Debian/postinst")
include (CPack)
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/awebc/sphinx.git
git@gitee.com:awebc/sphinx.git
awebc
sphinx
sphinx
master

搜索帮助