byproduct

This commit is contained in:
Andrei Astafev 2021-08-02 14:33:04 +03:00
parent aea565decf
commit 3bf9e8f148
2 changed files with 7 additions and 3 deletions

View File

@ -6,13 +6,15 @@ list(APPEND _ext_project_args
myx-notifications myx-notifications
SOURCE_DIR ${CMAKE_SOURCE_DIR}/thirdparty/myx-notifications SOURCE_DIR ${CMAKE_SOURCE_DIR}/thirdparty/myx-notifications
INSTALL_DIR ${CMAKE_BINARY_DIR} INSTALL_DIR ${CMAKE_BINARY_DIR}
BUILD_BYPRODUCTS ${CMAKE_BINARY_DIR}/${CMAKE_INSTALL_LIBDIR}/libmyx-notifications.a
CMAKE_ARGS ${CMLIB_EXT_PROJ_DEFAULT_ARGS} CMAKE_ARGS ${CMLIB_EXT_PROJ_DEFAULT_ARGS}
<SOURCE_DIR>) <SOURCE_DIR>)
if(MyxNotificationsThirdparty_FIND_COMPONENTS STREQUAL "headers") if(MyxNotificationsThirdparty_FIND_COMPONENTS STREQUAL "headers")
list(APPEND _ext_project_args list(APPEND _ext_project_args
BUILD_COMMAND true BUILD_COMMAND true
INSTALL_COMMAND ${CMAKE_MAKE_PROGRAM} myx-notifications-install-headers) INSTALL_COMMAND ${CMAKE_MAKE_PROGRAM} myx-notifications-install-headers)
else()
list(APPEND _ext_project_args
BUILD_BYPRODUCTS ${CMAKE_BINARY_DIR}/${CMAKE_INSTALL_LIBDIR}/libmyx-notifications.a)
endif() endif()
ExternalProject_Add(${_ext_project_args}) ExternalProject_Add(${_ext_project_args})
unset(_ext_project_args) unset(_ext_project_args)

View File

@ -6,14 +6,16 @@ list(APPEND _ext_project_args
myxlib myxlib
SOURCE_DIR ${CMAKE_SOURCE_DIR}/thirdparty/myxlib SOURCE_DIR ${CMAKE_SOURCE_DIR}/thirdparty/myxlib
INSTALL_DIR ${CMAKE_BINARY_DIR} INSTALL_DIR ${CMAKE_BINARY_DIR}
BUILD_BYPRODUCTS ${CMAKE_BINARY_DIR}/${CMAKE_INSTALL_LIBDIR}/libmyx-qt.a
${CMAKE_BINARY_DIR}/${CMAKE_INSTALL_LIBDIR}/libmyx-filesystem.a
CMAKE_ARGS ${CMLIB_EXT_PROJ_DEFAULT_ARGS} CMAKE_ARGS ${CMLIB_EXT_PROJ_DEFAULT_ARGS}
<SOURCE_DIR>) <SOURCE_DIR>)
if(MyxlibThirdparty_FIND_COMPONENTS STREQUAL "headers") if(MyxlibThirdparty_FIND_COMPONENTS STREQUAL "headers")
list(APPEND _ext_project_args list(APPEND _ext_project_args
BUILD_COMMAND true BUILD_COMMAND true
INSTALL_COMMAND ${CMAKE_MAKE_PROGRAM} myxlib-install-headers) INSTALL_COMMAND ${CMAKE_MAKE_PROGRAM} myxlib-install-headers)
else()
list(APPEND _ext_project_args
BUILD_BYPRODUCTS ${CMAKE_BINARY_DIR}/${CMAKE_INSTALL_LIBDIR}/libmyx-qt.a
${CMAKE_BINARY_DIR}/${CMAKE_INSTALL_LIBDIR}/libmyx-filesystem.a)
endif() endif()
ExternalProject_Add(${_ext_project_args}) ExternalProject_Add(${_ext_project_args})
unset(_ext_project_args) unset(_ext_project_args)