Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 19 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,19 @@ if (NOT BOOST_COBALT_IS_ROOT)
endif()
endif()

if (BOOST_SUPERPROJECT_VERSION AND NOT CMAKE_VERSION VERSION_LESS 3.13)
set(boost_cobalt_install_targets boost_cobalt boost_cobalt_io)
if (TARGET boost_cobalt_io_ssl)
list(APPEND boost_cobalt_install_targets boost_cobalt_io_ssl)
endif()

boost_install(
TARGETS ${boost_cobalt_install_targets}
VERSION "${BOOST_SUPERPROJECT_VERSION}"
HEADER_DIRECTORY include
)
endif()

if(BUILD_TESTING AND EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/test/CMakeLists.txt")
add_subdirectory(test)
endif()
Expand Down Expand Up @@ -260,7 +273,12 @@ else()
endif()

if(BOOST_COBALT_INSTALL AND NOT BOOST_SUPERPROJECT_VERSION)
install(TARGETS boost_cobalt boost_cobalt_io
set(boost_cobalt_install_targets boost_cobalt boost_cobalt_io)
if (TARGET boost_cobalt_io_ssl)
list(APPEND boost_cobalt_install_targets boost_cobalt_io_ssl)
endif()

install(TARGETS ${boost_cobalt_install_targets}
RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}"
LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}"
ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}"
Expand Down