2016-10-27 02:49:01 +08:00
|
|
|
#header-only library
|
2020-10-31 03:47:16 +08:00
|
|
|
|
2018-11-21 07:19:09 +08:00
|
|
|
vcpkg_from_github(
|
|
|
|
OUT_SOURCE_PATH SOURCE_PATH
|
|
|
|
REPO chriskohlhoff/asio
|
2022-07-29 13:35:30 +08:00
|
|
|
REF 4915cfd8a1653c157a1480162ae5601318553eb8 #vasio-1-23-0
|
|
|
|
SHA512 4fb30b82d51726b621fe80a17dac0ce23d4d48c813d3d45b394aac4e6de68008f142da848d6d6f2a69f70147dfb52b7bac4f45b15385ac227d94fd2e15f9e4b3
|
2018-11-21 07:19:09 +08:00
|
|
|
HEAD_REF master
|
2016-10-04 08:03:45 +08:00
|
|
|
)
|
|
|
|
|
2019-06-29 04:50:32 +08:00
|
|
|
# Always use "ASIO_STANDALONE" to avoid boost dependency
|
2020-10-31 03:47:16 +08:00
|
|
|
vcpkg_replace_string("${SOURCE_PATH}/asio/include/asio/detail/config.hpp" "defined(ASIO_STANDALONE)" "!defined(VCPKG_DISABLE_ASIO_STANDALONE)")
|
2019-06-29 04:50:32 +08:00
|
|
|
|
2019-06-05 07:01:27 +08:00
|
|
|
# CMake install
|
2021-09-03 04:27:36 +08:00
|
|
|
file(COPY "${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt" DESTINATION "${SOURCE_PATH}")
|
|
|
|
vcpkg_cmake_configure(
|
|
|
|
SOURCE_PATH "${SOURCE_PATH}"
|
2019-06-05 07:01:27 +08:00
|
|
|
)
|
2021-09-03 04:27:36 +08:00
|
|
|
vcpkg_cmake_install()
|
2019-06-05 07:01:27 +08:00
|
|
|
|
2021-09-03 04:27:36 +08:00
|
|
|
vcpkg_cmake_config_fixup()
|
2019-06-05 07:01:27 +08:00
|
|
|
file(INSTALL
|
2021-09-03 04:27:36 +08:00
|
|
|
"${CMAKE_CURRENT_LIST_DIR}/asio-config.cmake"
|
|
|
|
DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}"
|
2019-06-05 07:01:27 +08:00
|
|
|
)
|
2021-09-03 04:27:36 +08:00
|
|
|
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug")
|
2019-06-05 07:01:27 +08:00
|
|
|
|
2016-10-04 08:03:45 +08:00
|
|
|
# Handle copyright
|
2021-09-03 04:27:36 +08:00
|
|
|
file(INSTALL "${SOURCE_PATH}/asio/LICENSE_1_0.txt" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
|