Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
deps: update libuv to 1.51.0
PR-URL: #58124
Backport-PR-URL: #60579
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Rafael Gonzaga <[email protected]>
Reviewed-By: Santiago Gimeno <[email protected]>
Reviewed-By: Juan José Arboleda <[email protected]>
Reviewed-By: Antoine du Hamel <[email protected]>
Signed-off-by: Juan José Arboleda <[email protected]>
  • Loading branch information
nodejs-github-bot authored and juanarbol committed Nov 5, 2025
commit 4a50b37f3bcbcc25288f30cf7cee42364f8ea808
2 changes: 1 addition & 1 deletion deps/uv/.readthedocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ version: 2

sphinx:
builder: html
configuration: null
configuration: docs/src/conf.py
fail_on_warning: false

build:
Expand Down
56 changes: 56 additions & 0 deletions deps/uv/AUTHORS
Original file line number Diff line number Diff line change
Expand Up @@ -548,3 +548,59 @@ liuxiang88 <[email protected]>
Jeffrey H. Johnson <[email protected]>
Abdirahim Musse <[email protected]>
小明 <[email protected]>
Shuduo Sang <[email protected]>
Keith Winstein <[email protected]>
michalbiesek <[email protected]>
Alois Klink <[email protected]>
SmorkalovG <[email protected]>
Pleuvens <[email protected]>
jolai <[email protected]>
Julien Roncaglia <[email protected]>
prubel <[email protected]>
Per Allansson <[email protected]>
Matheus Izvekov <[email protected]>
Christian Heimlich <[email protected]>
Hao Hu <[email protected]>
matoro <[email protected]>
Bo Anderson <[email protected]>
Ardi Nugraha <[email protected]>
Anton Bachin <[email protected]>
Trevor Flynn <[email protected]>
Andy Pan <[email protected]>
Viacheslav Muravyev <[email protected]>
Anthony Alayo <[email protected]>
Thomas Walter <[email protected]>
hiiizxf <[email protected]>
Geddy <[email protected]>
Farzin Monsef <[email protected]>
tgolang <[email protected]>
josedelinux <[email protected]>
Hüseyin Açacak <[email protected]>
Uilian Ries <[email protected]>
Olivier Valentin <[email protected]>
郑苏波 (Super Zheng) <[email protected]>
zeertzjq <[email protected]>
Ian Butterworth <[email protected]>
握猫猫 <[email protected]>
Zuohui Yang <[email protected]>
Edigleysson Silva (Edy) <[email protected]>
Raihaan Shouhell <[email protected]>
Rialbat <[email protected]>
Adam <[email protected]>
Poul T Lomholt <[email protected]>
Thad House <[email protected]>
Julian A Avar C <[email protected]>
amcgoogan <[email protected]>
Rafael Gonzaga <[email protected]>
Morten Engelhardt Olsen <[email protected]>
Andrey <[email protected]>
Julio Jordán <[email protected]>
Jinho Jang <[email protected]>
Velikiy Kirill <[email protected]>
rainlow <[email protected]>
Paolo Insogna <[email protected]>
Robert Nagy <[email protected]>
mugitya03 <[email protected]>
Itay Bookstein <[email protected]>
crupest <[email protected]>
AE1020 <[email protected]>
66 changes: 55 additions & 11 deletions deps/uv/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
cmake_minimum_required(VERSION 3.4)
cmake_minimum_required(VERSION 3.10)

if(POLICY CMP0091)
cmake_policy(SET CMP0091 NEW) # Enable MSVC_RUNTIME_LIBRARY setting
Expand All @@ -20,7 +20,7 @@ include(CTest)
set(CMAKE_C_VISIBILITY_PRESET hidden)
set(CMAKE_C_STANDARD_REQUIRED ON)
set(CMAKE_C_EXTENSIONS ON)
set(CMAKE_C_STANDARD 90)
set(CMAKE_C_STANDARD 11)

set(CMAKE_EXPORT_COMPILE_COMMANDS ON)

Expand Down Expand Up @@ -81,15 +81,20 @@ if(TSAN)
endif()

if(UBSAN)
cmake_minimum_required(VERSION 3.13)
list(APPEND uv_defines __UBSAN__=1)
if(CMAKE_C_COMPILER_ID MATCHES "AppleClang|GNU|Clang")
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fno-omit-frame-pointer -fsanitize=undefined")
set (CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -fno-omit-frame-pointer -fsanitize=undefined")
set (CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -fno-omit-frame-pointer -fsanitize=undefined")
elseif(MSVC)
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /fsanitize=undefined")
add_compile_options("-fsanitize=undefined" "-fno-sanitize-recover=undefined")
if (NOT WIN32)
add_link_options("-fsanitize=undefined")
endif()
if(MSVC)
add_compile_options("/Oy-")
else()
add_compile_options("-fno-omit-frame-pointer")
endif()
else()
message(SEND_ERROR "UndefinedBehaviorSanitizer support requires clang, gcc, or msvc. Try again with -DCMAKE_C_COMPILER.")
message(SEND_ERROR "UndefinedBehaviorSanitizer support requires clang or gcc. Try again with -DCMAKE_C_COMPILER.")
endif()
endif()

Expand Down Expand Up @@ -161,6 +166,11 @@ list(APPEND uv_cflags ${lint-utf8-msvc} )
check_c_compiler_flag(-fno-strict-aliasing UV_F_STRICT_ALIASING)
list(APPEND uv_cflags $<$<BOOL:${UV_F_STRICT_ALIASING}>:-fno-strict-aliasing>)

if (MSVC)
# Error on calling undeclared functions.
list(APPEND uv_cflags "/we4013")
endif()

set(uv_sources
src/fs-poll.c
src/idna.c
Expand All @@ -176,7 +186,7 @@ set(uv_sources
src/version.c)

if(WIN32)
list(APPEND uv_defines WIN32_LEAN_AND_MEAN _WIN32_WINNT=0x0602)
list(APPEND uv_defines WIN32_LEAN_AND_MEAN _WIN32_WINNT=0x0A00 _CRT_DECLARE_NONSTDC_NAMES=0)
list(APPEND uv_libraries
psapi
user32
Expand All @@ -186,7 +196,7 @@ if(WIN32)
ws2_32
dbghelp
ole32
uuid)
shell32)
list(APPEND uv_sources
src/win/async.c
src/win/core.c
Expand Down Expand Up @@ -302,6 +312,7 @@ if(APPLE)
endif()

if(CMAKE_SYSTEM_NAME STREQUAL "GNU")
list(APPEND uv_defines _GNU_SOURCE _POSIX_C_SOURCE=200112 _XOPEN_SOURCE=500)
list(APPEND uv_libraries dl)
list(APPEND uv_sources
src/unix/bsd-ifaddrs.c
Expand Down Expand Up @@ -423,6 +434,7 @@ endif()

if(APPLE OR CMAKE_SYSTEM_NAME MATCHES "DragonFly|FreeBSD|Linux|NetBSD|OpenBSD")
list(APPEND uv_test_libraries util)
list(APPEND uv_libraries m)
endif()

if(CYGWIN OR MSYS)
Expand Down Expand Up @@ -477,7 +489,7 @@ if(CMAKE_SYSTEM_NAME STREQUAL "OS390")
endif()
target_link_libraries(uv_a ${uv_libraries})
set_target_properties(uv_a PROPERTIES OUTPUT_NAME "uv")
if(MSVC)
if(WIN32)
set_target_properties(uv_a PROPERTIES PREFIX "lib")
endif()

Expand Down Expand Up @@ -561,6 +573,7 @@ if(LIBUV_BUILD_TESTS)
test/test-hrtime.c
test/test-idle.c
test/test-idna.c
test/test-iouring-pollhup.c
test/test-ip4-addr.c
test/test-ip6-addr.c
test/test-ip-name.c
Expand All @@ -571,6 +584,7 @@ if(LIBUV_BUILD_TESTS)
test/test-loop-close.c
test/test-loop-configure.c
test/test-loop-handles.c
test/test-loop-oom.c
test/test-loop-stop.c
test/test-loop-time.c
test/test-metrics.c
Expand Down Expand Up @@ -638,6 +652,7 @@ if(LIBUV_BUILD_TESTS)
test/test-tcp-oob.c
test/test-tcp-open.c
test/test-tcp-read-stop.c
test/test-tcp-reuseport.c
test/test-tcp-read-stop-start.c
test/test-tcp-rst.c
test/test-tcp-shutdown-after-write.c
Expand All @@ -654,6 +669,8 @@ if(LIBUV_BUILD_TESTS)
test/test-thread-affinity.c
test/test-thread-equal.c
test/test-thread.c
test/test-thread-name.c
test/test-thread-priority.c
test/test-threadpool-cancel.c
test/test-threadpool.c
test/test-timer-again.c
Expand Down Expand Up @@ -685,6 +702,7 @@ if(LIBUV_BUILD_TESTS)
test/test-udp-send-unreachable.c
test/test-udp-try-send.c
test/test-udp-recv-in-a-row.c
test/test-udp-reuseport.c
test/test-uname.c
test/test-walk-handles.c
test/test-watcher-cross-stop.c)
Expand All @@ -701,6 +719,12 @@ if(LIBUV_BUILD_TESTS)
set_tests_properties(uv_test PROPERTIES ENVIRONMENT
"LIBPATH=${CMAKE_BINARY_DIR}:$ENV{LIBPATH}")
endif()
if(WIN32)
add_custom_command(TARGET uv_run_tests POST_BUILD
COMMAND "${CMAKE_COMMAND}" -E copy
"$<TARGET_FILE:uv_run_tests>"
"$<TARGET_FILE_DIR:uv_run_tests>/uv_run_tests_no_ext")
endif()
add_executable(uv_run_tests_a ${uv_test_sources} uv_win_longpath.manifest)
target_compile_definitions(uv_run_tests_a PRIVATE ${uv_defines})
target_compile_options(uv_run_tests_a PRIVATE ${uv_cflags})
Expand All @@ -717,6 +741,12 @@ if(LIBUV_BUILD_TESTS)
set_target_properties(uv_run_tests PROPERTIES LINKER_LANGUAGE CXX)
set_target_properties(uv_run_tests_a PROPERTIES LINKER_LANGUAGE CXX)
endif()
if(WIN32)
add_custom_command(TARGET uv_run_tests_a POST_BUILD
COMMAND "${CMAKE_COMMAND}" -E copy
"$<TARGET_FILE:uv_run_tests_a>"
"$<TARGET_FILE_DIR:uv_run_tests_a>/uv_run_tests_a_no_ext")
endif()
endif()

# Now for some gibbering horrors from beyond the stars...
Expand Down Expand Up @@ -761,8 +791,22 @@ endif()

if(MSVC)
set(CMAKE_DEBUG_POSTFIX d)
get_filename_component(CMAKE_C_COMPILER_DIR ${CMAKE_C_COMPILER} DIRECTORY)
if(ASAN)
file(INSTALL "${CMAKE_C_COMPILER_DIR}/llvm-symbolizer.exe" DESTINATION "${CMAKE_CURRENT_BINARY_DIR}")
file(INSTALL "${CMAKE_C_COMPILER_DIR}/clang_rt.asan_dynamic-x86_64.dll" DESTINATION "${CMAKE_CURRENT_BINARY_DIR}")
file(INSTALL "${CMAKE_C_COMPILER_DIR}/clang_rt.asan_dbg_dynamic-x86_64.dll" DESTINATION "${CMAKE_CURRENT_BINARY_DIR}")
endif()
endif()

if(BUILD_SHARED_LIBS)
set(LIB_SELECTED uv)
else()
set(LIB_SELECTED uv_a)
endif()

add_library(libuv::libuv ALIAS ${LIB_SELECTED})

message(STATUS "summary of build options:
Install prefix: ${CMAKE_INSTALL_PREFIX}
Target system: ${CMAKE_SYSTEM_NAME}
Expand Down
Loading
Loading