mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-12-05 19:57:51 +08:00
837261793a
* [asio] update to 1.23.0 * update version * add license * update version
30 lines
1.0 KiB
CMake
30 lines
1.0 KiB
CMake
#header-only library
|
|
|
|
vcpkg_from_github(
|
|
OUT_SOURCE_PATH SOURCE_PATH
|
|
REPO chriskohlhoff/asio
|
|
REF 4915cfd8a1653c157a1480162ae5601318553eb8 #vasio-1-23-0
|
|
SHA512 4fb30b82d51726b621fe80a17dac0ce23d4d48c813d3d45b394aac4e6de68008f142da848d6d6f2a69f70147dfb52b7bac4f45b15385ac227d94fd2e15f9e4b3
|
|
HEAD_REF master
|
|
)
|
|
|
|
# Always use "ASIO_STANDALONE" to avoid boost dependency
|
|
vcpkg_replace_string("${SOURCE_PATH}/asio/include/asio/detail/config.hpp" "defined(ASIO_STANDALONE)" "!defined(VCPKG_DISABLE_ASIO_STANDALONE)")
|
|
|
|
# CMake install
|
|
file(COPY "${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt" DESTINATION "${SOURCE_PATH}")
|
|
vcpkg_cmake_configure(
|
|
SOURCE_PATH "${SOURCE_PATH}"
|
|
)
|
|
vcpkg_cmake_install()
|
|
|
|
vcpkg_cmake_config_fixup()
|
|
file(INSTALL
|
|
"${CMAKE_CURRENT_LIST_DIR}/asio-config.cmake"
|
|
DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}"
|
|
)
|
|
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug")
|
|
|
|
# Handle copyright
|
|
file(INSTALL "${SOURCE_PATH}/asio/LICENSE_1_0.txt" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
|