Skip to content

Commit

Permalink
deps: upgrade to libuv 1.43.0
Browse files Browse the repository at this point in the history
Notable changes:

- `uv_ip_name()` has been added.
- On Windows, `uv_fs_read()` and `uv_fs_write()` now return
  `UV_EBADF` instead of `UV_EPERM` when the file descriptor
  was opened with incorrect flags. This matches the behavior
  on other platforms.
- Streams can be reset and attempted to read from after
  EOF is read.
- The main thread now has a valid ID instead of `NULL`.
- `uv_cpu_info()` now supports `aarch64`.
- Several minor issues related to mingw32 have been fixed.

PR-URL: #41398
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Beth Griggs <bgriggs@redhat.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
  • Loading branch information
cjihrig authored and danielleadams committed Feb 1, 2022
1 parent 2bc381e commit af6f1d5
Show file tree
Hide file tree
Showing 58 changed files with 985 additions and 608 deletions.
4 changes: 4 additions & 0 deletions deps/uv/.mailmap
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
A. Hauptmann <andreashauptmann@t-online.de>
AJ Heller <aj@drfloob.com> <hork@google.com>
Aaron Bieber <qbit@deftly.net> <deftly@gmail.com>
Alan Gutierrez <alan@prettyrobots.com> <alan@blogometer.com>
Andrius Bentkus <andrius.bentkus@gmail.com> <toxedvirus@gmail.com>
Expand All @@ -12,6 +13,7 @@ Brian White <mscdex@mscdex.net> <mscdex@gmail.com>
Caleb James DeLisle <cjd@hyperboria.ca> <cjd@cjdns.fr>
Christoph Iserlohn <christoph.iserlohn@innoq.com>
Darshan Sen <raisinten@gmail.com>
Darshan Sen <raisinten@gmail.com> <darshan.sen@postman.com>
David Carlier <devnexen@gmail.com>
Devchandra Meetei Leishangthem <dlmeetei@gmail.com>
Fedor Indutny <fedor.indutny@gmail.com> <fedor@indutny.com>
Expand All @@ -21,6 +23,7 @@ Isaac Z. Schlueter <i@izs.me>
Jason Williams <necmon@yahoo.com>
Jesse Gorzinski <jgorzinski@gmail.com>
Jesse Gorzinski <jgorzinski@gmail.com> <jgorzins@us.ibm.com>
Juan José Arboleda <soyjuanarbol@gmail.com>
Justin Venus <justin.venus@gmail.com> <justin.venus@orbitz.com>
Keno Fischer <kenof@stanford.edu> <kfischer+github@college.harvard.edu>
Keno Fischer <kenof@stanford.edu> <kfischer@college.harvard.edu>
Expand All @@ -46,6 +49,7 @@ Santiago Gimeno <santiago.gimeno@quantion.es> <santiago.gimeno@gmail.com>
Saúl Ibarra Corretgé <saghul@gmail.com>
Saúl Ibarra Corretgé <saghul@gmail.com> <s@saghul.net>
Shigeki Ohtsu <ohtsu@iij.ad.jp> <ohtsu@ohtsu.org>
Shuowang (Wayne) Zhang <shuowang.zhang@ibm.com>
TK-one <tk5641@naver.com>
Timothy J. Fontaine <tjfontaine@gmail.com>
Yasuhiro Matsumoto <mattn.jp@gmail.com>
Expand Down
17 changes: 17 additions & 0 deletions deps/uv/AUTHORS
Original file line number Diff line number Diff line change
Expand Up @@ -479,3 +479,20 @@ Joshua M. Clulow <josh@sysmgr.org>
Guilherme Íscaro <cabelitostos@gmail.com>
Martin Storsjö <martin@martin.st>
Claes Nästén <pekdon@gmail.com>
Mohamed Edrah <43171151+MSE99@users.noreply.github.com>
Supragya Raj <supragyaraj@gmail.com>
Ikko Ashimine <eltociear@gmail.com>
Sylvain Corlay <sylvain.corlay@gmail.com>
earnal <etienne.arnal@gmail.com>
YAKSH BARIYA <yakshbari4@gmail.com>
Ofek Lev <ofekmeister@gmail.com>
~locpyl-tidnyd <81016946+locpyl-tidnyd@users.noreply.github.com>
Evan Miller <emmiller@gmail.com>
Petr Menšík <pemensik@redhat.com>
Nicolas Noble <nicolasnoble@users.noreply.github.com>
AJ Heller <aj@drfloob.com>
Stacey Marshall <stacey.marshall@gmail.com>
Jesper Storm Bache <jsbache@users.noreply.github.com>
Campbell He <duskmoon314@users.noreply.github.com>
Andrey Hohutkin <andrey.hohutkin@gmail.com>
deal <halx99@live.com>
87 changes: 49 additions & 38 deletions deps/uv/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,26 @@ if(QEMU)
endif()

option(ASAN "Enable AddressSanitizer (ASan)" OFF)
if(ASAN AND CMAKE_C_COMPILER_ID MATCHES "AppleClang|GNU|Clang")
option(TSAN "Enable ThreadSanitizer (TSan)" OFF)

if((ASAN OR TSAN) AND NOT (CMAKE_C_COMPILER_ID MATCHES "AppleClang|GNU|Clang"))
message(SEND_ERROR "Sanitizer support requires clang or gcc. Try again with -DCMAKE_C_COMPILER.")
endif()

if(ASAN)
add_definitions(-D__ASAN__=1)
set (CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -fno-omit-frame-pointer -fsanitize=address")
set (CMAKE_SHARED_LINKER_FLAGS_DEBUG "${CMAKE_SHARED_LINKER_FLAGS_DEBUG} -fno-omit-frame-pointer -fsanitize=address")
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fno-omit-frame-pointer -fsanitize=address")
set (CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -fno-omit-frame-pointer -fsanitize=address")
set (CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -fno-omit-frame-pointer -fsanitize=address")
endif()

if(TSAN)
add_definitions(-D__TSAN__=1)
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fno-omit-frame-pointer -fsanitize=thread")
set (CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -fno-omit-frame-pointer -fsanitize=thread")
set (CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -fno-omit-frame-pointer -fsanitize=thread")
endif()

# Compiler check
string(CONCAT is-msvc $<OR:
$<C_COMPILER_ID:MSVC>,
Expand Down Expand Up @@ -418,7 +431,6 @@ if(LIBUV_BUILD_TESTS)
test/benchmark-thread.c
test/benchmark-udp-pummel.c
test/blackhole-server.c
test/dns-server.c
test/echo-server.c
test/run-benchmarks.c
test/runner.c)
Expand Down Expand Up @@ -477,6 +489,7 @@ if(LIBUV_BUILD_TESTS)
test/test-idna.c
test/test-ip4-addr.c
test/test-ip6-addr.c
test/test-ip-name.c
test/test-ipc-heavy-traffic-deadlock-bug.c
test/test-ipc-send-recv.c
test/test-ipc.c
Expand All @@ -490,7 +503,6 @@ if(LIBUV_BUILD_TESTS)
test/test-multiple-listen.c
test/test-mutexes.c
test/test-not-readable-nor-writable-on-read-error.c
test/test-not-readable-on-eof.c
test/test-not-writable-after-shutdown.c
test/test-osx-select.c
test/test-pass-always.c
Expand Down Expand Up @@ -518,6 +530,7 @@ if(LIBUV_BUILD_TESTS)
test/test-process-title.c
test/test-queue-foreach-delete.c
test/test-random.c
test/test-readable-on-eof.c
test/test-ref.c
test/test-run-nowait.c
test/test-run-once.c
Expand Down Expand Up @@ -574,6 +587,7 @@ if(LIBUV_BUILD_TESTS)
test/test-udp-alloc-cb-fail.c
test/test-udp-bind.c
test/test-udp-connect.c
test/test-udp-connect6.c
test/test-udp-create-socket-early.c
test/test-udp-dgram-too-big.c
test/test-udp-ipv6.c
Expand Down Expand Up @@ -625,46 +639,43 @@ if(LIBUV_BUILD_TESTS)
endif()
endif()

if(UNIX OR MINGW)
# Now for some gibbering horrors from beyond the stars...
foreach(lib IN LISTS uv_libraries)
list(APPEND LIBS "-l${lib}")
endforeach()
string(REPLACE ";" " " LIBS "${LIBS}")
# Consider setting project version via project() call?
file(STRINGS configure.ac configure_ac REGEX ^AC_INIT)
string(REGEX MATCH "([0-9]+)[.][0-9]+[.][0-9]+" PACKAGE_VERSION "${configure_ac}")
set(UV_VERSION_MAJOR "${CMAKE_MATCH_1}")
# The version in the filename is mirroring the behaviour of autotools.
set_target_properties(uv PROPERTIES
VERSION ${UV_VERSION_MAJOR}.0.0
SOVERSION ${UV_VERSION_MAJOR})
set(includedir ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_INCLUDEDIR})
set(libdir ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR})
set(prefix ${CMAKE_INSTALL_PREFIX})
configure_file(libuv.pc.in libuv.pc @ONLY)
configure_file(libuv-static.pc.in libuv-static.pc @ONLY)

install(DIRECTORY include/ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR})
install(FILES LICENSE DESTINATION ${CMAKE_INSTALL_DOCDIR})
install(FILES ${PROJECT_BINARY_DIR}/libuv.pc ${PROJECT_BINARY_DIR}/libuv-static.pc
DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig)
install(TARGETS uv LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR})
install(TARGETS uv_a ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR})
endif()
# Now for some gibbering horrors from beyond the stars...
foreach(lib IN LISTS uv_libraries)
list(APPEND LIBS "-l${lib}")
endforeach()
string(REPLACE ";" " " LIBS "${LIBS}")
# Consider setting project version via project() call?
file(STRINGS configure.ac configure_ac REGEX ^AC_INIT)
string(REGEX MATCH "([0-9]+)[.][0-9]+[.][0-9]+" PACKAGE_VERSION "${configure_ac}")
set(UV_VERSION_MAJOR "${CMAKE_MATCH_1}")
# The version in the filename is mirroring the behaviour of autotools.
set_target_properties(uv PROPERTIES
VERSION ${UV_VERSION_MAJOR}.0.0
SOVERSION ${UV_VERSION_MAJOR})
set(includedir ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_INCLUDEDIR})
set(libdir ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR})
set(prefix ${CMAKE_INSTALL_PREFIX})
configure_file(libuv.pc.in libuv.pc @ONLY)
configure_file(libuv-static.pc.in libuv-static.pc @ONLY)

install(DIRECTORY include/ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR})
install(FILES LICENSE DESTINATION ${CMAKE_INSTALL_DOCDIR})
install(FILES ${PROJECT_BINARY_DIR}/libuv.pc ${PROJECT_BINARY_DIR}/libuv-static.pc
DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig)
install(TARGETS uv EXPORT libuvConfig
RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR})
install(TARGETS uv_a ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR})
install(EXPORT libuvConfig DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/libuv)

if(MSVC)
install(DIRECTORY include/ DESTINATION include)
install(FILES LICENSE DESTINATION .)
install(TARGETS uv uv_a
RUNTIME DESTINATION lib/$<CONFIG>
ARCHIVE DESTINATION lib/$<CONFIG>)
set(CMAKE_DEBUG_POSTFIX d)
endif()

message(STATUS "summary of build options:
Install prefix: ${CMAKE_INSTALL_PREFIX}
Target system: ${CMAKE_SYSTEM_NAME}
Compiler:
C compiler: ${CMAKE_C_COMPILER}
C compiler: ${CMAKE_C_COMPILER} (${CMAKE_C_COMPILER_ID})
CFLAGS: ${CMAKE_C_FLAGS_${_build_type}} ${CMAKE_C_FLAGS}
")
91 changes: 90 additions & 1 deletion deps/uv/ChangeLog
Original file line number Diff line number Diff line change
@@ -1,4 +1,93 @@
2021.07.21, Version 1.42.0 (Stable)
2022.01.05, Version 1.43.0 (Stable), 988f2bfc4defb9a85a536a3e645834c161143ee0

Changes since version 1.42.0:

* run test named ip6_sin6_len (Jameson Nash)

* docs: fix wrong information about scheduling (Mohamed Edrah)

* unix: protect fork in uv_spawn from signals (Jameson Nash)

* drop only successfully sent packets post sendmmsg (Supragya Raj)

* test: fix typo in test-tty-escape-sequence-processing.c (Ikko Ashimine)

* cmake: use standard installation layout always (Sylvain Corlay)

* win,spawn: allow UNC path with forward slash (earnal)

* win,fsevent: fix uv_fs_event_stop() assert (Ben Noordhuis)

* unix: remove redundant include in unix.h (

* doc: mark SmartOS as Tier 3 support (

* doc: fix broken links for netbsd's sysctl manpage (

* misc: adjust stalebot deadline (

* test: remove `dns-server.c` as it is not used anywhere (

* build: fix non-cmake android builds (

* doc: replace pyuv with uvloop (

* asan: fix some tests (

* build: add experimental TSAN configuration (

* pipe: remove useless assertion (

* bsd: destroy mutex in uv__process_title_cleanup() (

* build: add windows build to CI (

* win,fs: fix error code in uv_fs_read() and uv_fs_write() ( Sen)

* build: add macos-latest to ci matrix (

* udp: fix &/&& typo in macro condition (

* build: install cmake package module (Petr Menšík)

* win: fix build for mingw32 (

* build: fix build failures with MinGW new headers (erw7)

* build: fix win build with cmake versions before v3.14 (

* unix: support aarch64 in uv_cpu_info() (

* linux: work around CIFS EPERM bug (

* sunos: Oracle Developer Studio support (

* Revert "sunos: Oracle Developer Studio support (

* sunos: Oracle Developer Studio support (

* stream: permit read after seeing EOF (

* thread: initialize uv_thread_self for all threads (

* kqueue: ignore write-end closed notifications (

* macos: fix the cfdata length in uv__get_cpu_speed ( Bache)

* unix,win: add uv_ip_name to get name from sockaddr (

* win,test: fix a few typos (AJ Heller)

* zos: use destructor for uv__threadpool_cleanup() ( Zhang)

* linux: use MemAvailable instead of MemFree (

* freebsd: call dlerror() only if necessary (

* bsd,windows,zos: fix udp disconnect EINVAL (


2021.07.21, Version 1.42.0 (Stable), 6ce14710da7079eb248868171f6343bc409ea3a4

Changes since version 1.41.0:

Expand Down
10 changes: 4 additions & 6 deletions deps/uv/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,6 @@ endif

test_run_tests_LDFLAGS =
test_run_tests_SOURCES = test/blackhole-server.c \
test/dns-server.c \
test/echo-server.c \
test/run-tests.c \
test/runner.c \
Expand Down Expand Up @@ -193,6 +192,7 @@ test_run_tests_SOURCES = test/blackhole-server.c \
test/test-idna.c \
test/test-ip4-addr.c \
test/test-ip6-addr.c \
test/test-ip-name.c \
test/test-ipc-heavy-traffic-deadlock-bug.c \
test/test-ipc-send-recv.c \
test/test-ipc.c \
Expand All @@ -207,7 +207,6 @@ test_run_tests_SOURCES = test/blackhole-server.c \
test/test-multiple-listen.c \
test/test-mutexes.c \
test/test-not-readable-nor-writable-on-read-error.c \
test/test-not-readable-on-eof.c \
test/test-not-writable-after-shutdown.c \
test/test-osx-select.c \
test/test-pass-always.c \
Expand Down Expand Up @@ -235,6 +234,7 @@ test_run_tests_SOURCES = test/blackhole-server.c \
test/test-process-title-threadsafe.c \
test/test-queue-foreach-delete.c \
test/test-random.c \
test/test-readable-on-eof.c \
test/test-ref.c \
test/test-run-nowait.c \
test/test-run-once.c \
Expand Down Expand Up @@ -291,6 +291,7 @@ test_run_tests_SOURCES = test/blackhole-server.c \
test/test-udp-alloc-cb-fail.c \
test/test-udp-bind.c \
test/test-udp-connect.c \
test/test-udp-connect6.c \
test/test-udp-create-socket-early.c \
test/test-udp-dgram-too-big.c \
test/test-udp-ipv6.c \
Expand Down Expand Up @@ -390,10 +391,7 @@ if ANDROID
uvinclude_HEADERS += include/uv/android-ifaddrs.h
libuv_la_CFLAGS += -D_GNU_SOURCE
libuv_la_SOURCES += src/unix/android-ifaddrs.c \
src/unix/pthread-fixes.c \
src/unix/random-getrandom.c \
src/unix/random-sysctl-linux.c \
src/unix/epoll.c
src/unix/pthread-fixes.c
endif

if CYGWIN
Expand Down
2 changes: 1 addition & 1 deletion deps/uv/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
libuv is a multi-platform support library with a focus on asynchronous I/O. It
was primarily developed for use by [Node.js][], but it's also
used by [Luvit](http://luvit.io/), [Julia](http://julialang.org/),
[pyuv](https://github.com/saghul/pyuv), and [others](https://github.com/libuv/libuv/blob/v1.x/LINKS.md).
[uvloop](https://github.com/MagicStack/uvloop), and [others](https://github.com/libuv/libuv/blob/v1.x/LINKS.md).

## Feature highlights

Expand Down
2 changes: 1 addition & 1 deletion deps/uv/SUPPORTED_PLATFORMS.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
| IBM i | Tier 2 | >= IBM i 7.2 | Maintainers: @libuv/ibmi |
| z/OS | Tier 2 | >= V2R2 | Maintainers: @libuv/zos |
| Linux with musl | Tier 2 | musl >= 1.0 | |
| SmartOS | Tier 2 | >= 14.4 | Maintainers: @libuv/smartos |
| SmartOS | Tier 3 | >= 14.4 | |
| Android | Tier 3 | NDK >= r15b | |
| MinGW | Tier 3 | MinGW32 and MinGW-w64 | |
| SunOS | Tier 3 | Solaris 121 and later | |
Expand Down
2 changes: 1 addition & 1 deletion deps/uv/configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.

AC_PREREQ(2.57)
AC_INIT([libuv], [1.42.0], [https://github.com/libuv/libuv/issues])
AC_INIT([libuv], [1.43.0], [https://github.com/libuv/libuv/issues])
AC_CONFIG_MACRO_DIR([m4])
m4_include([m4/libuv-extra-automake-flags.m4])
m4_include([m4/as_case.m4])
Expand Down
4 changes: 2 additions & 2 deletions deps/uv/docs/src/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ Overview

libuv is a multi-platform support library with a focus on asynchronous I/O. It
was primarily developed for use by `Node.js`_, but it's also used by `Luvit`_,
`Julia`_, `pyuv`_, and `others`_.
`Julia`_, `uvloop`_, and `others`_.

.. note::
In case you find errors in this documentation you can help by sending
Expand All @@ -16,7 +16,7 @@ was primarily developed for use by `Node.js`_, but it's also used by `Luvit`_,
.. _Node.js: https://nodejs.org
.. _Luvit: https://luvit.io
.. _Julia: https://julialang.org
.. _pyuv: https://github.com/saghul/pyuv
.. _uvloop: https://github.com/MagicStack/uvloop
.. _others: https://github.com/libuv/libuv/blob/v1.x/LINKS.md


Expand Down
Loading

0 comments on commit af6f1d5

Please sign in to comment.