vcpkg/scripts/test_ports/cmake/fix-dependency-libuv.patch
JonLiu1993 72ef222e77
[libuv] update to 1.44.1 and use official CMakeLists (#24745)
* [libuv] update to <1.44.1>

* update version

* fix ci error

* update version

* fix-ci-error

* [libuv] update to <1.44.1>

* update version

* add patch

* update version

* add option

* update version

* delete patch

* update evrsion

* fix ci error

* update version

* delete patch

* update evrsion

* Use official CMakeLists.txt

* Fix build type

* Re-fix, fix pkgconfig

* Fix usocket build

* Fix uvw build

* Fix wpilib build

* Fix cmake build

* Fix tensorpipe build

* Fix qpid-proton build

* modern portfile

* update version

* Add licese

* update version

* Update ports/usockets/CMakeLists.txt

* update version

* Add usage

* Apply suggestion

* version

* Disable to build examples

* version

* typo

* version

* Fix find_package

* version

* Update version

Co-authored-by: JackBoosY <yuzaiyang@beyondsoft.com>
Co-authored-by: Jack·Boos·Yu <47264268+JackBoosY@users.noreply.github.com>
2022-07-08 13:02:45 -07:00

29 lines
844 B
Diff

diff --git a/CMakeLists.txt b/CMakeLists.txt
index fdfe456..ef2d329 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -647,16 +647,16 @@ macro (CMAKE_BUILD_UTILITIES)
#---------------------------------------------------------------------
# Build libuv library.
if(CMAKE_USE_SYSTEM_LIBUV)
- if(WIN32)
- find_package(LibUV 1.38.0)
- else()
- find_package(LibUV 1.10.0)
- endif()
- if(NOT LIBUV_FOUND)
+ find_package(libuv CONFIG REQUIRED)
+ if(0)
message(FATAL_ERROR
"CMAKE_USE_SYSTEM_LIBUV is ON but a libuv is not found!")
endif()
- set(CMAKE_LIBUV_LIBRARIES LibUV::LibUV)
+ if (TARGET uv)
+ set(CMAKE_LIBUV_LIBRARIES uv)
+ else()
+ set(CMAKE_LIBUV_LIBRARIES uv_a)
+ endif()
else()
set(CMAKE_LIBUV_LIBRARIES cmlibuv)
add_subdirectory(Utilities/cmlibuv)