mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-11-24 04:19:08 +08:00
[trantor] fix: link to vcpkg c-ares target (#32735)
This commit is contained in:
parent
151c42c5f4
commit
ebf90b95b1
35
ports/trantor/000-fix-deps.patch
Normal file
35
ports/trantor/000-fix-deps.patch
Normal file
@ -0,0 +1,35 @@
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index 83bd458..ad56a27 100755
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -135,7 +135,7 @@ endif()
|
||||
|
||||
set(HAVE_C-ARES NO)
|
||||
if (BUILD_C-ARES)
|
||||
- find_package(c-ares)
|
||||
+ find_package(c-ares CONFIG)
|
||||
if(c-ares_FOUND)
|
||||
message(STATUS "c-ares found!")
|
||||
set(HAVE_C-ARES TRUE)
|
||||
@@ -143,7 +143,7 @@ if (BUILD_C-ARES)
|
||||
endif ()
|
||||
|
||||
if(HAVE_C-ARES)
|
||||
- target_link_libraries(${PROJECT_NAME} PRIVATE c-ares_lib)
|
||||
+ target_link_libraries(${PROJECT_NAME} PRIVATE c-ares::cares)
|
||||
set(TRANTOR_SOURCES
|
||||
${TRANTOR_SOURCES}
|
||||
trantor/net/inner/AresResolver.cc)
|
||||
diff --git a/cmake/templates/TrantorConfig.cmake.in b/cmake/templates/TrantorConfig.cmake.in
|
||||
index e18652d..6dad38e 100644
|
||||
--- a/cmake/templates/TrantorConfig.cmake.in
|
||||
+++ b/cmake/templates/TrantorConfig.cmake.in
|
||||
@@ -14,7 +14,7 @@ if(@OpenSSL_FOUND@)
|
||||
find_dependency(OpenSSL)
|
||||
endif()
|
||||
if(@c-ares_FOUND@)
|
||||
- find_dependency(c-ares)
|
||||
+ find_dependency(c-ares CONFIG)
|
||||
endif()
|
||||
find_dependency(Threads)
|
||||
# Compute paths
|
@ -5,6 +5,7 @@ vcpkg_from_github(
|
||||
SHA512 dd65938bebb2e6714e5603db3bfc82cd1a63395c17dce014147a41fdc74548cb526e1457a7472aa51bb80ce629a9935b4db9eeadf735efaf30899ef73f776a58
|
||||
HEAD_REF master
|
||||
PATCHES
|
||||
000-fix-deps.patch
|
||||
)
|
||||
|
||||
vcpkg_cmake_configure(
|
||||
|
@ -1,6 +1,7 @@
|
||||
{
|
||||
"name": "trantor",
|
||||
"version-semver": "1.5.11",
|
||||
"port-version": 1,
|
||||
"description": "A non-blocking I/O cross-platform TCP network library, using C++14",
|
||||
"homepage": "https://github.com/an-tao/trantor",
|
||||
"license": "BSD-2-Clause",
|
||||
|
@ -8222,7 +8222,7 @@
|
||||
},
|
||||
"trantor": {
|
||||
"baseline": "1.5.11",
|
||||
"port-version": 0
|
||||
"port-version": 1
|
||||
},
|
||||
"tre": {
|
||||
"baseline": "0.8.0",
|
||||
|
@ -1,5 +1,10 @@
|
||||
{
|
||||
"versions": [
|
||||
{
|
||||
"git-tree": "4ac910f7ba58f9ee8ceff1c8ac1d2dfa0200136f",
|
||||
"version-semver": "1.5.11",
|
||||
"port-version": 1
|
||||
},
|
||||
{
|
||||
"git-tree": "bdeefc43943ee1bd39f5c46db28a89b01e446b8f",
|
||||
"version-semver": "1.5.11",
|
||||
|
Loading…
Reference in New Issue
Block a user