mirror of
https://github.com/microsoft/vcpkg.git
synced 2025-06-07 16:52:53 +08:00
[brynet] Use vcpkg_from_github
This commit is contained in:
parent
19cb797838
commit
31d686e7e4
@ -1,4 +1,3 @@
|
|||||||
Source: brynet
|
Source: brynet
|
||||||
Version: 0.9.0
|
Version: 0.9.0
|
||||||
Description: A C++ cross platform high performance tcp network library, and support SSL/HTTP/Websocket.
|
Description: A C++ cross platform high performance tcp network library, and support SSL/HTTP/Websocket.
|
||||||
Build-Depends:
|
|
||||||
|
@ -1,42 +1,26 @@
|
|||||||
# Common Ambient Variables:
|
|
||||||
# CURRENT_BUILDTREES_DIR = ${VCPKG_ROOT_DIR}\buildtrees\${PORT}
|
|
||||||
# CURRENT_PACKAGES_DIR = ${VCPKG_ROOT_DIR}\packages\${PORT}_${TARGET_TRIPLET}
|
|
||||||
# CURRENT_PORT_DIR = ${VCPKG_ROOT_DIR}\ports\${PORT}
|
|
||||||
# PORT = current port name (zlib, etc)
|
|
||||||
# TARGET_TRIPLET = current triplet (x86-windows, x64-windows-static, etc)
|
|
||||||
# VCPKG_CRT_LINKAGE = C runtime linkage type (static, dynamic)
|
|
||||||
# VCPKG_LIBRARY_LINKAGE = target library linkage type (static, dynamic)
|
|
||||||
# VCPKG_ROOT_DIR = <C:\path\to\current\vcpkg>
|
|
||||||
# VCPKG_TARGET_ARCHITECTURE = target architecture (x64, x86, arm)
|
|
||||||
#
|
|
||||||
|
|
||||||
include(vcpkg_common_functions)
|
include(vcpkg_common_functions)
|
||||||
|
|
||||||
if(VCPKG_LIBRARY_LINKAGE STREQUAL dynamic)
|
if(VCPKG_LIBRARY_LINKAGE STREQUAL dynamic)
|
||||||
message(STATUS "Alembic does not support dynamic linkage. Building statically.")
|
message(STATUS "brynet does not support dynamic linkage. Building statically.")
|
||||||
set(VCPKG_LIBRARY_LINKAGE static)
|
set(VCPKG_LIBRARY_LINKAGE static)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
set(BRYNET_VERSION 0.9.0)
|
vcpkg_from_github(
|
||||||
|
OUT_SOURCE_PATH SOURCE_PATH
|
||||||
set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/brynet-${BRYNET_VERSION})
|
REPO IronsDu/brynet
|
||||||
vcpkg_download_distfile(ARCHIVE
|
REF v0.9.0
|
||||||
URLS "https://github.com/IronsDu/brynet/archive/v${BRYNET_VERSION}.zip"
|
SHA512 49543833be0d8eb2dce2b00a85d48087e9756b93febaae0c7cd83b7f44f9cd8d81976069f8b84344807bee2df785b80fbb65a1a93e8c6a9c942f9554063a05c1
|
||||||
FILENAME "v${BRYNET_VERSION}.zip"
|
HEAD_REF master
|
||||||
SHA512 a39bdffe6bb9b93bd6f21da0d59b172c2956c5f9366716dff01027f59660ca4d28ee557a42caa93d93047e041438a1de42ed22c67a3c2124d105a63381ac3685
|
|
||||||
)
|
)
|
||||||
vcpkg_extract_source_archive(${ARCHIVE})
|
|
||||||
|
|
||||||
vcpkg_configure_cmake(
|
vcpkg_configure_cmake(
|
||||||
SOURCE_PATH ${SOURCE_PATH}
|
SOURCE_PATH ${SOURCE_PATH}
|
||||||
PREFER_NINJA # Disable this option if project cannot be built with Ninja
|
PREFER_NINJA
|
||||||
# OPTIONS -DUSE_THIS_IN_ALL_BUILDS=1 -DUSE_THIS_TOO=2
|
|
||||||
# OPTIONS_RELEASE -DOPTIMIZE=1
|
|
||||||
# OPTIONS_DEBUG -DDEBUGGABLE=1
|
|
||||||
)
|
)
|
||||||
|
|
||||||
vcpkg_install_cmake()
|
vcpkg_install_cmake()
|
||||||
|
|
||||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
|
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
|
||||||
file(COPY ${CURRENT_BUILDTREES_DIR}/src/brynet-${BRYNET_VERSION}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/brynet)
|
|
||||||
|
file(COPY ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/brynet)
|
||||||
file(RENAME ${CURRENT_PACKAGES_DIR}/share/brynet/LICENSE ${CURRENT_PACKAGES_DIR}/share/brynet/copyright)
|
file(RENAME ${CURRENT_PACKAGES_DIR}/share/brynet/LICENSE ${CURRENT_PACKAGES_DIR}/share/brynet/copyright)
|
||||||
# Handle copyright
|
|
||||||
# file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/brynet RENAME copyright)
|
|
||||||
|
Loading…
Reference in New Issue
Block a user