1.99.76
This commit is contained in:
parent
7fbb5fb302
commit
1fe605e0f9
@ -1,4 +1,4 @@
|
|||||||
set(MYX_CMAKE_PACKAGE_VERSION "1.99.75")
|
set(MYX_CMAKE_PACKAGE_VERSION "1.99.76")
|
||||||
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.75 REQUIRED)
|
find_package(MyxCMake 1.99.76 REQUIRED)
|
||||||
else()
|
else()
|
||||||
if(MYX_CMAKE_USE_SYSTEM)
|
if(MYX_CMAKE_USE_SYSTEM)
|
||||||
find_package(MyxCMake 1.99.75 REQUIRED)
|
find_package(MyxCMake 1.99.76 REQUIRED)
|
||||||
else()
|
else()
|
||||||
include(${PROJECT_SOURCE_DIR}/cmake/myx/MyxCMakeConfig.cmake)
|
include(${PROJECT_SOURCE_DIR}/cmake/myx/MyxCMakeConfig.cmake)
|
||||||
endif()
|
endif()
|
||||||
|
@ -7,28 +7,28 @@ function(myx_qt5_target_setup NAME)
|
|||||||
|
|
||||||
cmake_parse_arguments(ARG "${options}" "${oneValueArgs}" "${multiValueArgs}" ${ARGN})
|
cmake_parse_arguments(ARG "${options}" "${oneValueArgs}" "${multiValueArgs}" ${ARGN})
|
||||||
|
|
||||||
get_target_property(type ${NAME} TYPE)
|
get_target_property(target_type ${NAME} TYPE)
|
||||||
|
|
||||||
foreach(iter ${ARG_COMPONENTS})
|
foreach(iter ${ARG_COMPONENTS})
|
||||||
if(type STREQUAL "INTERFACE_LIBRARY")
|
if(target_type STREQUAL "INTERFACE_LIBRARY")
|
||||||
target_include_directories(${NAME} INTERFACE ${Qt5${iter}_INCLUDE_DIRS})
|
target_include_directories(${NAME} INTERFACE ${Qt5${iter}_INCLUDE_DIRS})
|
||||||
else()
|
else()
|
||||||
target_include_directories(${NAME} PRIVATE ${Qt5${iter}_INCLUDE_DIRS})
|
target_include_directories(${NAME} PRIVATE ${Qt5${iter}_INCLUDE_DIRS})
|
||||||
endif()
|
endif()
|
||||||
if(type STREQUAL "EXECUTABLE" AND NOT iter STREQUAL "LinguistTools")
|
if(target_type STREQUAL "EXECUTABLE" AND NOT iter STREQUAL "LinguistTools")
|
||||||
target_link_libraries(${NAME} PRIVATE "Qt5::${iter}")
|
target_link_libraries(${NAME} PRIVATE "Qt5::${iter}")
|
||||||
endif()
|
endif()
|
||||||
endforeach()
|
endforeach()
|
||||||
|
|
||||||
foreach(iter ${ARG_PRIVATE})
|
foreach(iter ${ARG_PRIVATE})
|
||||||
if(type STREQUAL "INTERFACE_LIBRARY")
|
if(target_type STREQUAL "INTERFACE_LIBRARY")
|
||||||
target_include_directories(${NAME} INTERFACE ${Qt5${iter}_PRIVATE_INCLUDE_DIRS})
|
target_include_directories(${NAME} INTERFACE ${Qt5${iter}_PRIVATE_INCLUDE_DIRS})
|
||||||
else()
|
else()
|
||||||
target_include_directories(${NAME} PRIVATE ${Qt5${iter}_PRIVATE_INCLUDE_DIRS})
|
target_include_directories(${NAME} PRIVATE ${Qt5${iter}_PRIVATE_INCLUDE_DIRS})
|
||||||
endif()
|
endif()
|
||||||
endforeach()
|
endforeach()
|
||||||
|
|
||||||
if(type STREQUAL "EXECUTABLE")
|
if(target_type STREQUAL "EXECUTABLE")
|
||||||
target_compile_options(${NAME} PRIVATE ${Qt5Core_EXECUTABLE_COMPILE_FLAGS})
|
target_compile_options(${NAME} PRIVATE ${Qt5Core_EXECUTABLE_COMPILE_FLAGS})
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
@ -12,7 +12,7 @@ function(myx_target_setup NAME)
|
|||||||
myx_message_fatal_error("Target ${NAME} does not exists.")
|
myx_message_fatal_error("Target ${NAME} does not exists.")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
get_target_property(type ${NAME} TYPE)
|
get_target_property(target_type ${NAME} TYPE)
|
||||||
|
|
||||||
foreach(iter ${ARG_PACKAGES})
|
foreach(iter ${ARG_PACKAGES})
|
||||||
target_include_directories(${NAME} PRIVATE ${${iter}_INCLUDE_DIRS})
|
target_include_directories(${NAME} PRIVATE ${${iter}_INCLUDE_DIRS})
|
||||||
@ -48,7 +48,7 @@ function(myx_target_setup NAME)
|
|||||||
file(MAKE_DIRECTORY "${PROJECT_BINARY_DIR}/include")
|
file(MAKE_DIRECTORY "${PROJECT_BINARY_DIR}/include")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(NOT type STREQUAL "INTERFACE_LIBRARY")
|
if(NOT target_type STREQUAL "INTERFACE_LIBRARY")
|
||||||
target_include_directories(${PROJECT_NAME} PRIVATE
|
target_include_directories(${PROJECT_NAME} PRIVATE
|
||||||
$<BUILD_INTERFACE:${PROJECT_BINARY_DIR}/include>)
|
$<BUILD_INTERFACE:${PROJECT_BINARY_DIR}/include>)
|
||||||
|
|
||||||
@ -58,7 +58,7 @@ function(myx_target_setup NAME)
|
|||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(type STREQUAL "EXECUTABLE")
|
if(target_type STREQUAL "EXECUTABLE")
|
||||||
if(IS_DIRECTORY "${PROJECT_SOURCE_DIR}/include")
|
if(IS_DIRECTORY "${PROJECT_SOURCE_DIR}/include")
|
||||||
target_include_directories(${PROJECT_NAME} PRIVATE
|
target_include_directories(${PROJECT_NAME} PRIVATE
|
||||||
$<BUILD_INTERFACE:${PROJECT_SOURCE_DIR}/include>)
|
$<BUILD_INTERFACE:${PROJECT_SOURCE_DIR}/include>)
|
||||||
|
Loading…
Reference in New Issue
Block a user