2021-07-26 04:48:56 +09:00
|
|
|
vcpkg_check_linkage(ONLY_DYNAMIC_LIBRARY)
|
|
|
|
|
|
|
|
vcpkg_from_github(
|
|
|
|
OUT_SOURCE_PATH QUIC_SOURCE_PATH
|
|
|
|
REPO microsoft/msquic
|
2024-06-18 18:58:24 +00:00
|
|
|
REF "v${VERSION}"
|
2024-10-01 00:02:24 +03:00
|
|
|
SHA512 51afee7e28a7d6ae1b5491edd635e0c88a92a00bacedeaac632a0f19762e9940c9b819a9d33072d3553c004acd4ec0cdf645301f712b408498053de065b2b1cf
|
2021-07-26 04:48:56 +09:00
|
|
|
HEAD_REF master
|
|
|
|
PATCHES
|
2024-06-25 11:02:38 -07:00
|
|
|
fix-install.patch # Adjust install path of build outputs
|
|
|
|
fix-uwp-crt.patch # https://github.com/microsoft/msquic/pull/4373
|
|
|
|
fix-comparing-system-processor-with-win32.patch # https://github.com/microsoft/msquic/pull/4374
|
2024-09-03 23:23:39 +03:00
|
|
|
all_headers.patch
|
2021-07-26 04:48:56 +09:00
|
|
|
)
|
|
|
|
|
2024-06-25 11:02:38 -07:00
|
|
|
# This avoids a link error on x86-windows:
|
|
|
|
# LINK : fatal error LNK1268: inconsistent option 'NODEFAULTLIB:libucrt.lib' specified with /USEPROFILE but not with /GENPROFILE
|
|
|
|
file(REMOVE "${QUIC_SOURCE_PATH}/src/bin/winuser/pgo_x86/msquic.pgd")
|
|
|
|
|
2021-07-26 04:48:56 +09:00
|
|
|
vcpkg_from_github(
|
|
|
|
OUT_SOURCE_PATH OPENSSL_SOURCE_PATH
|
|
|
|
REPO quictls/openssl
|
2024-10-01 00:02:24 +03:00
|
|
|
REF openssl-3.1.7-quic1
|
|
|
|
SHA512 230f48a4ef20bfd492b512bd53816a7129d70849afc1426e9ce813273c01884d5474552ecaede05231ca354403f25e2325c972c9c7950ae66dae310800bd19e7
|
|
|
|
HEAD_REF openssl-3.1.7+quic
|
2021-07-26 04:48:56 +09:00
|
|
|
)
|
2024-06-25 11:02:38 -07:00
|
|
|
|
2024-10-01 00:02:24 +03:00
|
|
|
file(REMOVE_RECURSE "${QUIC_SOURCE_PATH}/submodules/openssl3")
|
|
|
|
file(RENAME "${OPENSSL_SOURCE_PATH}" "${QUIC_SOURCE_PATH}/submodules/openssl3")
|
2024-06-25 11:02:38 -07:00
|
|
|
|
2024-06-18 18:58:24 +00:00
|
|
|
vcpkg_from_github(
|
|
|
|
OUT_SOURCE_PATH XDP_WINDOWS
|
|
|
|
REPO microsoft/xdp-for-windows
|
2024-10-02 17:24:08 +03:00
|
|
|
REF v1.0.2
|
|
|
|
SHA512 1b26487fa79c8796d4b0d5e09f4fc9acb003d8e079189ec57a36ff03c9c2620829106fdbc4780e298872826f3a97f034d40e04d00a77ded97122874d13bfb145
|
2024-06-25 11:02:38 -07:00
|
|
|
HEAD_REF main
|
2024-06-18 18:58:24 +00:00
|
|
|
)
|
2024-06-25 11:02:38 -07:00
|
|
|
|
|
|
|
file(REMOVE_RECURSE "${QUIC_SOURCE_PATH}/submodules/xdp-for-windows")
|
|
|
|
file(RENAME "${XDP_WINDOWS}" "${QUIC_SOURCE_PATH}/submodules/xdp-for-windows")
|
2021-07-26 04:48:56 +09:00
|
|
|
|
|
|
|
vcpkg_find_acquire_program(PERL)
|
2024-06-25 11:02:38 -07:00
|
|
|
get_filename_component(PERL_EXE_PATH "${PERL}" DIRECTORY)
|
|
|
|
vcpkg_add_to_path("${PERL_EXE_PATH}")
|
2021-07-26 04:48:56 +09:00
|
|
|
|
|
|
|
if(NOT VCPKG_HOST_IS_WINDOWS)
|
|
|
|
find_program(MAKE make)
|
2024-06-25 11:02:38 -07:00
|
|
|
get_filename_component(MAKE_EXE_PATH "${MAKE}" DIRECTORY)
|
|
|
|
vcpkg_add_to_path(PREPEND "${MAKE_EXE_PATH}")
|
2021-07-26 04:48:56 +09:00
|
|
|
endif()
|
|
|
|
|
2024-06-26 21:37:24 -07:00
|
|
|
if(VCPKG_TARGET_IS_WINDOWS)
|
|
|
|
vcpkg_find_acquire_program(NASM)
|
|
|
|
get_filename_component(NASM_EXE_PATH "${NASM}" DIRECTORY)
|
|
|
|
vcpkg_add_to_path(PREPEND "${NASM_EXE_PATH}")
|
|
|
|
endif()
|
2021-07-26 04:48:56 +09:00
|
|
|
|
|
|
|
string(COMPARE EQUAL "${VCPKG_CRT_LINKAGE}" "static" STATIC_CRT)
|
|
|
|
|
|
|
|
vcpkg_cmake_configure(
|
2024-06-25 11:02:38 -07:00
|
|
|
SOURCE_PATH "${QUIC_SOURCE_PATH}"
|
2021-07-26 04:48:56 +09:00
|
|
|
OPTIONS
|
|
|
|
-DQUIC_SOURCE_LINK=OFF
|
2024-10-01 00:02:24 +03:00
|
|
|
-DQUIC_TLS=openssl3
|
2021-07-26 04:48:56 +09:00
|
|
|
-DQUIC_USE_SYSTEM_LIBCRYPTO=OFF
|
|
|
|
-DQUIC_BUILD_PERF=OFF
|
|
|
|
-DQUIC_BUILD_TEST=OFF
|
2024-06-25 11:02:38 -07:00
|
|
|
"-DQUIC_STATIC_LINK_CRT=${STATIC_CRT}"
|
2024-09-03 19:24:56 +00:00
|
|
|
"-DQUIC_STATIC_LINK_PARTIAL_CRT=${STATIC_CRT}"
|
2024-06-25 11:02:38 -07:00
|
|
|
"-DQUIC_UWP_BUILD=${VCPKG_TARGET_IS_UWP}"
|
2021-07-26 04:48:56 +09:00
|
|
|
)
|
|
|
|
|
|
|
|
vcpkg_cmake_install()
|
2024-09-12 19:20:52 +00:00
|
|
|
vcpkg_cmake_config_fixup()
|
2021-07-26 04:48:56 +09:00
|
|
|
vcpkg_copy_pdbs()
|
2024-06-18 18:58:24 +00:00
|
|
|
vcpkg_install_copyright(FILE_LIST "${QUIC_SOURCE_PATH}/LICENSE")
|
2024-06-25 11:02:38 -07:00
|
|
|
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share"
|
|
|
|
"${CURRENT_PACKAGES_DIR}/debug/include"
|
2021-07-26 04:48:56 +09:00
|
|
|
)
|