diff --git a/doc/contributing/maintaining/maintaining-dependencies.md b/doc/contributing/maintaining/maintaining-dependencies.md index 293d3f09360180..2e5f348f7bae04 100644 --- a/doc/contributing/maintaining/maintaining-dependencies.md +++ b/doc/contributing/maintaining/maintaining-dependencies.md @@ -8,30 +8,30 @@ directories to create the Node.js binaries. All dependencies are located within the `deps` directory. This a list of all the dependencies: -* [acorn 8.11.2][] -* [ada 2.7.4][] -* [base64 0.5.1][] -* [brotli 1.0.9][] -* [c-ares 1.20.1][] -* [cjs-module-lexer 1.2.2][] +* [acorn][] +* [ada][] +* [base64][] +* [brotli][] +* [c-ares][] +* [cjs-module-lexer][] * [corepack][] -* [googletest 76bb2af][] -* [histogram 0.11.8][] -* [icu-small 74.1][] -* [libuv 1.46.0][] -* [llhttp 8.1.0][] -* [minimatch 9.0.3][] -* [nghttp2 1.58.0][] -* [nghttp3 0.7.0][] -* [ngtcp2 0.8.1][] -* [npm 9.6.7][] -* [openssl 3.0.8][] -* [postject 1.0.0-alpha.6][] -* [simdutf 4.0.4][] -* [undici 5.27.2][] -* [uvwasi 0.0.19][] -* [V8 11.3.244.8][] -* [zlib 1.3.0.1-motley-dd5fc13][] +* [googletest][] +* [histogram][] +* [icu-small][] +* [libuv][] +* [llhttp][] +* [minimatch][] +* [nghttp2][] +* [nghttp3][] +* [ngtcp2][] +* [npm][] +* [openssl][] +* [postject][] +* [simdutf][] +* [undici][] +* [uvwasi][] +* [V8][] +* [zlib][] Any code which meets one or more of these conditions should be managed as a dependency: @@ -144,35 +144,35 @@ takes care of npm update, it is maintained by the npm team. ## Dependency list -### acorn 8.11.2 +### acorn The [acorn](https://github.com/acornjs/acorn) dependency is a JavaScript parser. [acorn-walk](https://github.com/acornjs/acorn/tree/master/acorn-walk) is an abstract syntax tree walker for the ESTree format. -### ada 2.7.4 +### ada The [ada](https://github.com/ada-url/ada) dependency is a fast and spec-compliant URL parser written in C++. -### base64 0.5.1 +### base64 The [base64](https://github.com/aklomp/base64) dependency is a base64 stream encoding/decoding library in C99 with SIMD and OpenMP acceleration. It also contains wrapper functions to encode/decode simple length-delimited strings. -### brotli 1.0.9 +### brotli The [brotli](https://github.com/google/brotli) dependency is used for the homonym generic-purpose lossless compression algorithm. -### c-ares 1.20.1 +### c-ares The [c-ares](https://github.com/c-ares/c-ares) is a C library for asynchronous DNS requests. -### cjs-module-lexer 1.2.2 +### cjs-module-lexer The [cjs-module-lexer](https://github.com/nodejs/node/tree/HEAD/deps/cjs-module-lexer) dependency is used within the Node.js ESM implementation to detect the @@ -189,52 +189,52 @@ In practical terms, Corepack will let you use Yarn and pnpm without having to install them - just like what currently happens with npm, which is shipped by Node.js by default. -### googletest 76bb2af +### googletest The [googletest](https://github.com/google/googletest) dependency is Google’s C++ testing and mocking framework. -### histogram 0.11.8 +### histogram The [histogram](https://github.com/HdrHistogram/HdrHistogram_c) dependency is a C port of High Dynamic Range (HDR) Histogram. -### icu-small 74.1 +### ic The [icu](http://site.icu-project.org) is widely used set of C/C++ and Java libraries providing Unicode and Globalization support for software applications. See [maintaining-icu][] for more informations. -### libuv 1.46.0 +### libuv The [libuv](https://github.com/libuv/libuv) dependency is a multi-platform support library with a focus on asynchronous I/O. It was primarily developed for use by Node.js. -### llhttp 8.1.0 +### llhttp The [llhttp](https://github.com/nodejs/llhttp) dependency is the http parser used by Node.js. See [maintaining-http][] for more informations. -### minimatch 9.0.3 +### minimatch The [minimatch](https://github.com/isaacs/minimatch) dependency is a minimal matching utility. -### nghttp2 1.58.0 +### nghttp2 The [nghttp2](https://github.com/nghttp2/nghttp2) dependency is a C library implementing HTTP/2 protocol. See [maintaining-http][] for more informations. -### nghttp3 0.7.0 +### nghttp3 The [nghttp3](https://github.com/ngtcp2/nghttp3) dependency is HTTP/3 library written in C. See ngtcp2 for more informations. -### ngtcp2 0.8.1 +### ngtcp2 The ngtcp2 and nghttp3 dependencies provide the core functionality for QUIC and HTTP/3. @@ -254,7 +254,7 @@ The `nghttp3` library depends on `ngtcp2`. Both should always be updated together. From `ngtcp2` we only want the contents of the `lib` and `crypto` directories; from `nghttp3` we only want the contents of the `lib` directory. -### npm 9.6.7 +### npm The [npm](https://github.com/npm/cli) dependency is the package manager for JavaScript. @@ -269,7 +269,7 @@ are at the discretion of the release and LTS teams. This process only covers full updates to new versions of npm. Cherry-picked changes can be reviewed and landed via the normal consensus seeking process. -### openssl 3.0.8 +### openssl The [openssl](https://github.com/quictls/openssl) dependency is a fork of OpenSSL to enable QUIC. @@ -281,23 +281,23 @@ the main openssl/openssl releases with the addition of APIs to support the QUIC protocol. See [maintaining-openssl][] for more informations. -### postject 1.0.0-alpha.6 +### postject The [postject](https://github.com/nodejs/postject) dependency is used for the [Single Executable strategic initiative](https://github.com/nodejs/single-executable). -### simdutf 4.0.4 +### simdutf The [simdutf](https://github.com/simdutf/simdutf) dependency is a C++ library for fast UTF-8 decoding and encoding. -### undici 5.27.2 +### undici The [undici](https://github.com/nodejs/undici) dependency is an HTTP/1.1 client, written from scratch for Node.js.. See [maintaining-http][] for more informations. -### uvwasi 0.0.19 +### uvwasi The [uvwasi](https://github.com/nodejs/uvwasi) dependency implements the WASI system call API, so that WebAssembly runtimes can easily @@ -305,48 +305,48 @@ implement WASI calls. Under the hood, uvwasi leverages libuv where possible for maximum portability. See [maintaining-web-assembly][] for more informations. -### V8 11.3.244.8 +### V8 [V8](https://chromium.googlesource.com/v8/v8.git/) is Google's open source high-performance JavaScript and WebAssembly engine, written in C++. See [maintaining-V8][] for more informations. -### zlib 1.3.0.1-motley-dd5fc13 +### zlib The [zlib](https://chromium.googlesource.com/chromium/src/+/refs/heads/main/third_party/zlib) dependency lossless data-compression library, it comes from the Chromium team's zlib fork which incorporated performance improvements not currently available in standard zlib. -[acorn 8.11.2]: #acorn-8112 -[ada 2.7.4]: #ada-274 -[base64 0.5.1]: #base64-051 -[brotli 1.0.9]: #brotli-109 -[c-ares 1.20.1]: #c-ares-1201 -[cjs-module-lexer 1.2.2]: #cjs-module-lexer-122 +[acorn]: #acorn +[ada]: #ada +[base64]: #base64 +[brotli]: #brotli +[c-ares]: #c-ares +[cjs-module-lexer]: #cjs-module-lexer [corepack]: #corepack [dependency-update-action]: ../../../.github/workflows/tools.yml -[googletest 76bb2af]: #googletest-76bb2af -[histogram 0.11.8]: #histogram-0118 -[icu-small 74.1]: #icu-small-741 -[libuv 1.46.0]: #libuv-1460 -[llhttp 8.1.0]: #llhttp-810 +[googletest]: #googletest +[histogram]: #histogram +[icu-small]: #icu-small +[libuv]: #libuv +[llhttp]: #llhttp [maintaining-V8]: ./maintaining-V8.md [maintaining-cjs-module-lexer]: ./maintaining-cjs-module-lexer.md [maintaining-http]: ./maintaining-http.md [maintaining-icu]: ./maintaining-icu.md [maintaining-openssl]: ./maintaining-openssl.md [maintaining-web-assembly]: ./maintaining-web-assembly.md -[minimatch 9.0.3]: #minimatch-903 -[nghttp2 1.58.0]: #nghttp2-1580 -[nghttp3 0.7.0]: #nghttp3-070 -[ngtcp2 0.8.1]: #ngtcp2-081 -[npm 9.6.7]: #npm-967 -[openssl 3.0.8]: #openssl-308 -[postject 1.0.0-alpha.6]: #postject-100-alpha6 -[simdutf 4.0.4]: #simdutf-404 -[undici 5.27.2]: #undici-5272 +[minimatch]: #minimatch +[nghttp2]: #nghttp2 +[nghttp3]: #nghttp3 +[ngtcp2]: #ngtcp2 +[npm]: #npm +[openssl]: #openssl +[postject]: #postject +[simdutf]: #simdutf +[undici]: #undici [update-openssl-action]: ../../../.github/workflows/update-openssl.yml -[uvwasi 0.0.19]: #uvwasi-0019 -[v8 11.3.244.8]: #v8-1132448 -[zlib 1.3.0.1-motley-dd5fc13]: #zlib-1301-motley-dd5fc13 +[uvwasi]: #uvwasi +[v8]: #v8 +[zlib]: #zlib diff --git a/tools/dep_updaters/update-openssl.sh b/tools/dep_updaters/update-openssl.sh index 850c7c6f7c5d96..bef379b707a04e 100755 --- a/tools/dep_updaters/update-openssl.sh +++ b/tools/dep_updaters/update-openssl.sh @@ -105,14 +105,11 @@ EOF rm -rf "$DEPS_DIR/openssl/openssl" mv "$WORKSPACE/openssl" "$DEPS_DIR/openssl/" - # Update the version number - update_dependency_version "openssl" "$NEW_VERSION_V3" echo "All done!" echo "" echo "Please git add openssl, and commit the new version:" echo "" echo "$ git add -A deps/openssl/openssl" - echo "$ git add doc/contributing/maintaining/maintaining-dependencies.md" echo "$ git commit -m \"deps: upgrade openssl sources to quictls/openssl-$NEW_VERSION_V3\"" echo "" # The last line of the script should always print the new version, diff --git a/tools/dep_updaters/update-v8-patch.sh b/tools/dep_updaters/update-v8-patch.sh index 53f10766426be3..799bf7697191b7 100755 --- a/tools/dep_updaters/update-v8-patch.sh +++ b/tools/dep_updaters/update-v8-patch.sh @@ -26,11 +26,6 @@ CURRENT_PATCH_VERSION=$(grep "#define V8_PATCH_LEVEL" "$DEPS_DIR/v8/include/v8-v NEW_VERSION="$CURRENT_MAJOR_VERSION.$CURRENT_MINOR_VERSION.$CURRENT_BUILD_VERSION.$CURRENT_PATCH_VERSION" -# Update the version number. We have to call it twice because V8 is written -# both in lowercase and uppdercase -update_dependency_version "v8" "$NEW_VERSION" -update_dependency_version "V8" "$NEW_VERSION" - echo "All done!" echo "" diff --git a/tools/dep_updaters/utils.sh b/tools/dep_updaters/utils.sh index c5888ff42364e8..8c86b772c96571 100644 --- a/tools/dep_updaters/utils.sh +++ b/tools/dep_updaters/utils.sh @@ -1,6 +1,7 @@ #!/bin/sh ROOT=$(cd "$(dirname "$0")/../.." && pwd) +export ROOT # This function compare new version with current version of a depdendency and # exit the script if the versions are the same @@ -34,15 +35,11 @@ finalize_version_update() { new_version="$2" extra_files="$3" - # Update the version number on maintaining-dependencies.md - update_dependency_version "$package_name" "$new_version" - echo "All done!" echo "" echo "Please git add $package_name and commit the new version:" echo "" echo "$ git add -A deps/$package_name $extra_files" - echo "$ git add doc/contributing/maintaining/maintaining-dependencies.md" echo "$ git commit -m \"deps: update $package_name to $new_version\"" echo "" @@ -80,20 +77,3 @@ log_and_verify_sha256sum() { fi fi } - -# This function update the version of a maintained dependency in -# https://github.com/nodejs/node/blob/main/doc/contributing/maintaining/maintaining-dependencies.md -# -# $1 is the package name e.g. 'acorn', 'ada', 'base64' etc. See that file -# for a complete list of package name -# $2 is the new version. -update_dependency_version() { - package_name="$1" - new_version="$2" - deps_file_path="$ROOT/doc/contributing/maintaining/maintaining-dependencies.md" - # Remove version dots for anchor markdown - version_no_dots=$(echo "$new_version" | sed -e 's/\.//g') - perl -i -pe 's|^\* \['"$package_name"'.*|* ['"$package_name"' '"$new_version"'][]|' "$deps_file_path" - perl -i -pe 's|^\['"$package_name"'.*\]: #'"$package_name"'.*|['"$package_name"' '"$new_version"']: #'"$package_name"'-'"$version_no_dots"'|' "$deps_file_path" - perl -i -pe 's|^### '"$package_name"'.*|### '"$package_name"' '"$new_version"'|' "$deps_file_path" -}