diff --git a/MyxCMakeConfig.cmake b/MyxCMakeConfig.cmake index f6a21b4..d606d3c 100644 --- a/MyxCMakeConfig.cmake +++ b/MyxCMakeConfig.cmake @@ -2,11 +2,6 @@ cmake_policy(PUSH) cmake_policy(SET CMP0057 NEW) # IN_LIST operator get_filename_component(MYX_CMAKE_SOURCE_DIR "${CMAKE_CURRENT_LIST_FILE}" DIRECTORY) -get_filename_component(PROJECT_CMAKE_DIR ${MYX_CMAKE_SOURCE_DIR} DIRECTORY) - -if(NOT MYX_CMAKE_SOURCE_DIR STREQUAL "${PROJECT_SOURCE_DIR}/cmake/myx") - message(FATAL_ERROR "MyxCMake library should be placed in ${PROJECT_SOURCE_DIR}/cmake/myx directory") -endif() set(MYX_CMAKE_BACKPORTS_DIR "${MYX_CMAKE_SOURCE_DIR}/backports") set(MYX_CMAKE_LIB_DIR "${MYX_CMAKE_SOURCE_DIR}/lib") @@ -23,4 +18,8 @@ include(${MYX_CMAKE_LIB_DIR}/DirectoriesGuards.cmake) include(${MYX_CMAKE_LIB_DIR}/SemanticProjectVersion.cmake) include(${MYX_CMAKE_LIB_DIR}/NinjaGeneratorWrapper.cmake) +unset(MYX_CMAKE_SOURCE_DIR) +unset(MYX_CMAKE_BACKPORTS_DIR) +unset(MYX_CMAKE_LIB_DIR) + cmake_policy(POP) diff --git a/lib/SemanticProjectVersion.cmake b/lib/SemanticProjectVersion.cmake index 7835349..d40dbc8 100644 --- a/lib/SemanticProjectVersion.cmake +++ b/lib/SemanticProjectVersion.cmake @@ -10,7 +10,6 @@ function(myx_project_version_int) # cmake-format: off myx_is_semantic_project_version() math(EXPR v "(${PROJECT_VERSION_MAJOR} << 32) + (${PROJECT_VERSION_MINOR} << 16) + ${PROJECT_VERSION_PATCH}") - myx_message_notice(aaaa ${v}) set_property(GLOBAL PROPERTY PROJECT_VERSION_INT ${v}) # cmake-format: on endfunction()