1.99.71
This commit is contained in:
parent
3157540238
commit
386faf578e
@ -1,4 +1,4 @@
|
|||||||
set(MYX_CMAKE_PACKAGE_VERSION "1.99.70")
|
set(MYX_CMAKE_PACKAGE_VERSION "1.99.71")
|
||||||
if(MYX_CMAKE_PACKAGE_VERSION VERSION_LESS PACKAGE_FIND_VERSION)
|
if(MYX_CMAKE_PACKAGE_VERSION VERSION_LESS PACKAGE_FIND_VERSION)
|
||||||
set(PACKAGE_VERSION_COMPATIBLE FALSE)
|
set(PACKAGE_VERSION_COMPATIBLE FALSE)
|
||||||
else()
|
else()
|
||||||
|
@ -36,10 +36,10 @@ if(MYX_CMAKE_DIR)
|
|||||||
set(ENV{MYX_CMAKE_DIR} ${MYX_CMAKE_DIR})
|
set(ENV{MYX_CMAKE_DIR} ${MYX_CMAKE_DIR})
|
||||||
endif()
|
endif()
|
||||||
if(DEFINED ENV{MYX_CMAKE_DIR})
|
if(DEFINED ENV{MYX_CMAKE_DIR})
|
||||||
find_package(MyxCMake 1.99.70 REQUIRED)
|
find_package(MyxCMake 1.99.71 REQUIRED)
|
||||||
else()
|
else()
|
||||||
if(MYX_CMAKE_USE_SYSTEM)
|
if(MYX_CMAKE_USE_SYSTEM)
|
||||||
find_package(MyxCMake 1.99.70 REQUIRED)
|
find_package(MyxCMake 1.99.71 REQUIRED)
|
||||||
else()
|
else()
|
||||||
include(${PROJECT_SOURCE_DIR}/cmake/myx/MyxCMakeConfig.cmake)
|
include(${PROJECT_SOURCE_DIR}/cmake/myx/MyxCMakeConfig.cmake)
|
||||||
endif()
|
endif()
|
||||||
|
@ -30,4 +30,4 @@ git tag $V
|
|||||||
git push --tags
|
git push --tags
|
||||||
git tag -d $V
|
git tag -d $V
|
||||||
git push --all
|
git push --all
|
||||||
tea r c -t $V --tag $V -a build/myx-cmake-$V.tar.xz
|
tea r c --repo cmake/myx -t $V --tag $V -a build/myx-cmake-$V.tar.xz
|
||||||
|
@ -19,6 +19,8 @@ myx_add_library
|
|||||||
|
|
||||||
include_guard(GLOBAL)
|
include_guard(GLOBAL)
|
||||||
|
|
||||||
|
# Переменная `CMAKE_CURRENT_FUNCTION_LIST_DIR` позволяет определить
|
||||||
|
# каталог файла.
|
||||||
if(${CMAKE_VERSION} VERSION_LESS "3.17.0")
|
if(${CMAKE_VERSION} VERSION_LESS "3.17.0")
|
||||||
set(CMAKE_CURRENT_FUNCTION_LIST_DIR ${CMAKE_CURRENT_LIST_DIR})
|
set(CMAKE_CURRENT_FUNCTION_LIST_DIR ${CMAKE_CURRENT_LIST_DIR})
|
||||||
endif()
|
endif()
|
||||||
|
@ -17,32 +17,32 @@ get_filename_component(project_binary_dir "${PROJECT_BINARY_DIR}" REALPATH)
|
|||||||
get_filename_component(cmake_install_prefix "${CMAKE_INSTALL_PREFIX}" REALPATH)
|
get_filename_component(cmake_install_prefix "${CMAKE_INSTALL_PREFIX}" REALPATH)
|
||||||
|
|
||||||
if(cmake_install_prefix STREQUAL cmake_binary_dir)
|
if(cmake_install_prefix STREQUAL cmake_binary_dir)
|
||||||
myx_message_error(
|
myx_message_fatal_error(
|
||||||
"Myx: Cannot install into build directory ${CMAKE_INSTALL_PREFIX}.")
|
"Myx: Cannot install into build directory ${CMAKE_INSTALL_PREFIX}.")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(cmake_install_prefix STREQUAL cmake_source_dir)
|
if(cmake_install_prefix STREQUAL cmake_source_dir)
|
||||||
myx_message_error(
|
myx_message_fatal_error(
|
||||||
"Myx: Cannot install into source directory ${CMAKE_INSTALL_PREFIX}.")
|
"Myx: Cannot install into source directory ${CMAKE_INSTALL_PREFIX}.")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(cmake_install_prefix STREQUAL project_binary_dir)
|
if(cmake_install_prefix STREQUAL project_binary_dir)
|
||||||
myx_message_error(
|
myx_message_fatal_error(
|
||||||
"Myx: Cannot install into build directory ${CMAKE_INSTALL_PREFIX}.")
|
"Myx: Cannot install into build directory ${CMAKE_INSTALL_PREFIX}.")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(cmake_install_prefix STREQUAL project_source_dir)
|
if(cmake_install_prefix STREQUAL project_source_dir)
|
||||||
myx_message_error(
|
myx_message_fatal_error(
|
||||||
"Myx: Cannot install into source directory ${CMAKE_INSTALL_PREFIX}.")
|
"Myx: Cannot install into source directory ${CMAKE_INSTALL_PREFIX}.")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(cmake_binary_dir STREQUAL cmake_source_dir)
|
if(cmake_binary_dir STREQUAL cmake_source_dir)
|
||||||
myx_message_error(
|
myx_message_fatal_error(
|
||||||
"Myx: Cannot build in source directory ${CMAKE_SOURCE_DIR}")
|
"Myx: Cannot build in source directory ${CMAKE_SOURCE_DIR}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(project_binary_dir STREQUAL project_source_dir)
|
if(project_binary_dir STREQUAL project_source_dir)
|
||||||
myx_message_error(
|
myx_message_fatal_error(
|
||||||
"Myx: Cannot build in source directory ${CMAKE_SOURCE_DIR}")
|
"Myx: Cannot build in source directory ${CMAKE_SOURCE_DIR}")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
@ -1,3 +1,24 @@
|
|||||||
|
#[=======================================================================[.rst:
|
||||||
|
FetchContent_Add
|
||||||
|
----------------
|
||||||
|
|
||||||
|
Вспомогательная функция для `FetchContent_Declare()`::
|
||||||
|
|
||||||
|
FetchContent_Add(NAME
|
||||||
|
[ GIT_REPOSITORY repo ] |
|
||||||
|
[ GIT_REMOTE remote ] |
|
||||||
|
[ GIT_PATH path ])
|
||||||
|
|
||||||
|
Обязательные параметры: `NAME` - идентификатор загружаемого ресурса.
|
||||||
|
Параметр `GIT_REPOSITORY` определяет имя репозитория по умолчанию.
|
||||||
|
Если указана пара параметров `GIT_REMOTE` и `GIT_PATH` и у git-репозитория
|
||||||
|
основного проекта указан удалённый репозиторий с именем, определяемым
|
||||||
|
переменной `GIT_REMOTE`, то адрес репозитория для получения проекта
|
||||||
|
изменяется. В этом случае загрузка будет производиться с сервера,
|
||||||
|
определяемого из адреса с меткой `GIT_REMOTE`, и по пути `GIT_PATH`.
|
||||||
|
|
||||||
|
#]=======================================================================]
|
||||||
|
|
||||||
include_guard(GLOBAL)
|
include_guard(GLOBAL)
|
||||||
|
|
||||||
# Обязательно в глобальной области
|
# Обязательно в глобальной области
|
||||||
|
Loading…
Reference in New Issue
Block a user