加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
CMakeLists.txt 1.31 KB
一键复制 编辑 原始数据 按行查看 历史
ShikiSuen 提交于 2022-06-14 11:26 . Asking Clang to use C++20 to compile.
cmake_minimum_required(VERSION 3.6)
project(fcitx5-e04input VERSION 2.2.2)
find_package(ECM REQUIRED 1.0.0)
set(CMAKE_MODULE_PATH ${ECM_MODULE_PATH} "${CMAKE_CURRENT_SOURCE_DIR}/cmake" ${CMAKE_MODULE_PATH})
find_package(Fcitx5Core REQUIRED)
find_package(Fcitx5Utils REQUIRED)
find_package(fmt REQUIRED)
find_package(Gettext REQUIRED)
include(FeatureSummary)
include(GNUInstallDirs)
include(ECMSetupVersion)
include(ECMUninstallTarget)
option(ENABLE_TEST "Build Test" On)
# Setup some compiler option that is generally useful and compatible with Fcitx 5 (C++17)
include("${FCITX_INSTALL_CMAKECONFIG_DIR}/Fcitx5Utils/Fcitx5CompilerSettings.cmake")
# So that `make install` does not also install Google Test
set(INSTALL_GTEST OFF CACHE BOOL "" FORCE)
set(CXX_STANDARD_REQUIRED 20)
add_subdirectory(src)
add_subdirectory(data)
add_subdirectory(po)
message(STATUS "CMAKE_INSTALL_PREFIX ${CMAKE_INSTALL_PREFIX}")
message(STATUS "CMAKE_INSTALL_DATADIR ${CMAKE_INSTALL_DATADIR}")
# E04Input data
configure_file(data/data.txt e04input-data.txt)
configure_file(data/add-phrase-hook.sh e04input-add-phrase-hook.sh)
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/e04input-data.txt" DESTINATION "${FCITX_INSTALL_PKGDATADIR}/data")
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/e04input-add-phrase-hook.sh" DESTINATION "${FCITX_INSTALL_PKGDATADIR}/data")
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化