Skip to content

Commit bce9d7e

Browse files
nodejs-github-botjuanarbol
authored andcommitted
deps: update libuv to 1.51.0
PR-URL: nodejs#58124 Backport-PR-URL: nodejs#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]>
1 parent 9fc5b2b commit bce9d7e

File tree

292 files changed

+13436
-8557
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

292 files changed

+13436
-8557
lines changed

deps/uv/.readthedocs.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ version: 2
22

33
sphinx:
44
builder: html
5-
configuration: null
5+
configuration: docs/src/conf.py
66
fail_on_warning: false
77

88
build:

deps/uv/AUTHORS

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -548,3 +548,59 @@ liuxiang88 <[email protected]>
548548
Jeffrey H. Johnson <[email protected]>
549549
Abdirahim Musse <[email protected]>
550550
551+
Shuduo Sang <[email protected]>
552+
Keith Winstein <[email protected]>
553+
michalbiesek <[email protected]>
554+
Alois Klink <[email protected]>
555+
SmorkalovG <[email protected]>
556+
557+
558+
Julien Roncaglia <[email protected]>
559+
560+
Per Allansson <[email protected]>
561+
Matheus Izvekov <[email protected]>
562+
Christian Heimlich <[email protected]>
563+
564+
565+
Bo Anderson <[email protected]>
566+
Ardi Nugraha <[email protected]>
567+
Anton Bachin <[email protected]>
568+
Trevor Flynn <[email protected]>
569+
570+
Viacheslav Muravyev <[email protected]>
571+
Anthony Alayo <[email protected]>
572+
Thomas Walter <[email protected]>
573+
574+
575+
Farzin Monsef <[email protected]>
576+
577+
josedelinux <[email protected]>
578+
Hüseyin Açacak <[email protected]>
579+
Uilian Ries <[email protected]>
580+
Olivier Valentin <[email protected]>
581+
郑苏波 (Super Zheng) <[email protected]>
582+
583+
Ian Butterworth <[email protected]>
584+
握猫猫 <[email protected]>
585+
Zuohui Yang <[email protected]>
586+
Edigleysson Silva (Edy) <[email protected]>
587+
Raihaan Shouhell <[email protected]>
588+
589+
590+
Poul T Lomholt <[email protected]>
591+
Thad House <[email protected]>
592+
Julian A Avar C <[email protected]>
593+
amcgoogan <[email protected]>
594+
Rafael Gonzaga <[email protected]>
595+
Morten Engelhardt Olsen <[email protected]>
596+
597+
Julio Jordán <[email protected]>
598+
Jinho Jang <[email protected]>
599+
Velikiy Kirill <[email protected]>
600+
601+
Paolo Insogna <[email protected]>
602+
Robert Nagy <[email protected]>
603+
mugitya03 <[email protected]>
604+
Itay Bookstein <[email protected]>
605+
606+

deps/uv/CMakeLists.txt

Lines changed: 55 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
cmake_minimum_required(VERSION 3.4)
1+
cmake_minimum_required(VERSION 3.10)
22

33
if(POLICY CMP0091)
44
cmake_policy(SET CMP0091 NEW) # Enable MSVC_RUNTIME_LIBRARY setting
@@ -20,7 +20,7 @@ include(CTest)
2020
set(CMAKE_C_VISIBILITY_PRESET hidden)
2121
set(CMAKE_C_STANDARD_REQUIRED ON)
2222
set(CMAKE_C_EXTENSIONS ON)
23-
set(CMAKE_C_STANDARD 90)
23+
set(CMAKE_C_STANDARD 11)
2424

2525
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
2626

@@ -81,15 +81,20 @@ if(TSAN)
8181
endif()
8282

8383
if(UBSAN)
84+
cmake_minimum_required(VERSION 3.13)
8485
list(APPEND uv_defines __UBSAN__=1)
8586
if(CMAKE_C_COMPILER_ID MATCHES "AppleClang|GNU|Clang")
86-
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fno-omit-frame-pointer -fsanitize=undefined")
87-
set (CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -fno-omit-frame-pointer -fsanitize=undefined")
88-
set (CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -fno-omit-frame-pointer -fsanitize=undefined")
89-
elseif(MSVC)
90-
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /fsanitize=undefined")
87+
add_compile_options("-fsanitize=undefined" "-fno-sanitize-recover=undefined")
88+
if (NOT WIN32)
89+
add_link_options("-fsanitize=undefined")
90+
endif()
91+
if(MSVC)
92+
add_compile_options("/Oy-")
93+
else()
94+
add_compile_options("-fno-omit-frame-pointer")
95+
endif()
9196
else()
92-
message(SEND_ERROR "UndefinedBehaviorSanitizer support requires clang, gcc, or msvc. Try again with -DCMAKE_C_COMPILER.")
97+
message(SEND_ERROR "UndefinedBehaviorSanitizer support requires clang or gcc. Try again with -DCMAKE_C_COMPILER.")
9398
endif()
9499
endif()
95100

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

169+
if (MSVC)
170+
# Error on calling undeclared functions.
171+
list(APPEND uv_cflags "/we4013")
172+
endif()
173+
164174
set(uv_sources
165175
src/fs-poll.c
166176
src/idna.c
@@ -176,7 +186,7 @@ set(uv_sources
176186
src/version.c)
177187

178188
if(WIN32)
179-
list(APPEND uv_defines WIN32_LEAN_AND_MEAN _WIN32_WINNT=0x0602)
189+
list(APPEND uv_defines WIN32_LEAN_AND_MEAN _WIN32_WINNT=0x0A00 _CRT_DECLARE_NONSTDC_NAMES=0)
180190
list(APPEND uv_libraries
181191
psapi
182192
user32
@@ -186,7 +196,7 @@ if(WIN32)
186196
ws2_32
187197
dbghelp
188198
ole32
189-
uuid)
199+
shell32)
190200
list(APPEND uv_sources
191201
src/win/async.c
192202
src/win/core.c
@@ -302,6 +312,7 @@ if(APPLE)
302312
endif()
303313

304314
if(CMAKE_SYSTEM_NAME STREQUAL "GNU")
315+
list(APPEND uv_defines _GNU_SOURCE _POSIX_C_SOURCE=200112 _XOPEN_SOURCE=500)
305316
list(APPEND uv_libraries dl)
306317
list(APPEND uv_sources
307318
src/unix/bsd-ifaddrs.c
@@ -423,6 +434,7 @@ endif()
423434

424435
if(APPLE OR CMAKE_SYSTEM_NAME MATCHES "DragonFly|FreeBSD|Linux|NetBSD|OpenBSD")
425436
list(APPEND uv_test_libraries util)
437+
list(APPEND uv_libraries m)
426438
endif()
427439

428440
if(CYGWIN OR MSYS)
@@ -477,7 +489,7 @@ if(CMAKE_SYSTEM_NAME STREQUAL "OS390")
477489
endif()
478490
target_link_libraries(uv_a ${uv_libraries})
479491
set_target_properties(uv_a PROPERTIES OUTPUT_NAME "uv")
480-
if(MSVC)
492+
if(WIN32)
481493
set_target_properties(uv_a PROPERTIES PREFIX "lib")
482494
endif()
483495

@@ -561,6 +573,7 @@ if(LIBUV_BUILD_TESTS)
561573
test/test-hrtime.c
562574
test/test-idle.c
563575
test/test-idna.c
576+
test/test-iouring-pollhup.c
564577
test/test-ip4-addr.c
565578
test/test-ip6-addr.c
566579
test/test-ip-name.c
@@ -571,6 +584,7 @@ if(LIBUV_BUILD_TESTS)
571584
test/test-loop-close.c
572585
test/test-loop-configure.c
573586
test/test-loop-handles.c
587+
test/test-loop-oom.c
574588
test/test-loop-stop.c
575589
test/test-loop-time.c
576590
test/test-metrics.c
@@ -638,6 +652,7 @@ if(LIBUV_BUILD_TESTS)
638652
test/test-tcp-oob.c
639653
test/test-tcp-open.c
640654
test/test-tcp-read-stop.c
655+
test/test-tcp-reuseport.c
641656
test/test-tcp-read-stop-start.c
642657
test/test-tcp-rst.c
643658
test/test-tcp-shutdown-after-write.c
@@ -654,6 +669,8 @@ if(LIBUV_BUILD_TESTS)
654669
test/test-thread-affinity.c
655670
test/test-thread-equal.c
656671
test/test-thread.c
672+
test/test-thread-name.c
673+
test/test-thread-priority.c
657674
test/test-threadpool-cancel.c
658675
test/test-threadpool.c
659676
test/test-timer-again.c
@@ -685,6 +702,7 @@ if(LIBUV_BUILD_TESTS)
685702
test/test-udp-send-unreachable.c
686703
test/test-udp-try-send.c
687704
test/test-udp-recv-in-a-row.c
705+
test/test-udp-reuseport.c
688706
test/test-uname.c
689707
test/test-walk-handles.c
690708
test/test-watcher-cross-stop.c)
@@ -701,6 +719,12 @@ if(LIBUV_BUILD_TESTS)
701719
set_tests_properties(uv_test PROPERTIES ENVIRONMENT
702720
"LIBPATH=${CMAKE_BINARY_DIR}:$ENV{LIBPATH}")
703721
endif()
722+
if(WIN32)
723+
add_custom_command(TARGET uv_run_tests POST_BUILD
724+
COMMAND "${CMAKE_COMMAND}" -E copy
725+
"$<TARGET_FILE:uv_run_tests>"
726+
"$<TARGET_FILE_DIR:uv_run_tests>/uv_run_tests_no_ext")
727+
endif()
704728
add_executable(uv_run_tests_a ${uv_test_sources} uv_win_longpath.manifest)
705729
target_compile_definitions(uv_run_tests_a PRIVATE ${uv_defines})
706730
target_compile_options(uv_run_tests_a PRIVATE ${uv_cflags})
@@ -717,6 +741,12 @@ if(LIBUV_BUILD_TESTS)
717741
set_target_properties(uv_run_tests PROPERTIES LINKER_LANGUAGE CXX)
718742
set_target_properties(uv_run_tests_a PROPERTIES LINKER_LANGUAGE CXX)
719743
endif()
744+
if(WIN32)
745+
add_custom_command(TARGET uv_run_tests_a POST_BUILD
746+
COMMAND "${CMAKE_COMMAND}" -E copy
747+
"$<TARGET_FILE:uv_run_tests_a>"
748+
"$<TARGET_FILE_DIR:uv_run_tests_a>/uv_run_tests_a_no_ext")
749+
endif()
720750
endif()
721751

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

762792
if(MSVC)
763793
set(CMAKE_DEBUG_POSTFIX d)
794+
get_filename_component(CMAKE_C_COMPILER_DIR ${CMAKE_C_COMPILER} DIRECTORY)
795+
if(ASAN)
796+
file(INSTALL "${CMAKE_C_COMPILER_DIR}/llvm-symbolizer.exe" DESTINATION "${CMAKE_CURRENT_BINARY_DIR}")
797+
file(INSTALL "${CMAKE_C_COMPILER_DIR}/clang_rt.asan_dynamic-x86_64.dll" DESTINATION "${CMAKE_CURRENT_BINARY_DIR}")
798+
file(INSTALL "${CMAKE_C_COMPILER_DIR}/clang_rt.asan_dbg_dynamic-x86_64.dll" DESTINATION "${CMAKE_CURRENT_BINARY_DIR}")
799+
endif()
800+
endif()
801+
802+
if(BUILD_SHARED_LIBS)
803+
set(LIB_SELECTED uv)
804+
else()
805+
set(LIB_SELECTED uv_a)
764806
endif()
765807

808+
add_library(libuv::libuv ALIAS ${LIB_SELECTED})
809+
766810
message(STATUS "summary of build options:
767811
Install prefix: ${CMAKE_INSTALL_PREFIX}
768812
Target system: ${CMAKE_SYSTEM_NAME}

0 commit comments

Comments
 (0)