mirror of
https://github.com/nodejs/node.git
synced 2026-11-29 14:27:57 -05:00
tools: fix zconf.h path
Use the `DEPS_DIR` variable to build the path instead of hardcoding it. PR-URL: https://github.com/nodejs/node/pull/48089 Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com> Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
This commit is contained in:
1 parent
415bf7f532
commit
0c8c383583
1 file changed
+2
-2
@@ -6,7 +6,7 @@ BASE_DIR=$(cd "$(dirname "$0")/../.." && pwd)
|
||||
DEPS_DIR="$BASE_DIR/deps"
|
||||
|
||||
CURRENT_VERSION=$(grep "#define ZLIB_VERSION" "$DEPS_DIR/zlib/zlib.h" | sed -n "s/^.*VERSION \"\(.*\)\"/\1/p")
|
||||
|
||||
|
||||
NEW_VERSION_ZLIB_H=$(curl -s "https://chromium.googlesource.com/chromium/src/+/refs/heads/main/third_party/zlib/zlib.h?format=TEXT" | base64 --decode)
|
||||
|
||||
NEW_VERSION=$(printf '%s' "$NEW_VERSION_ZLIB_H" | grep "#define ZLIB_VERSION" | sed -n "s/^.*VERSION \"\(.*\)\"/\1/p")
|
||||
@@ -47,7 +47,7 @@ mkdir "$DEPS_DIR/zlib/win32"
|
||||
|
||||
mv "$DEPS_DIR/zlib.def" "$DEPS_DIR/zlib/win32"
|
||||
|
||||
perl -i -pe 's|^#include "chromeconf.h"|//#include "chromeconf.h"|' deps/zlib/zconf.h
|
||||
perl -i -pe 's|^#include "chromeconf.h"|//#include "chromeconf.h"|' "$DEPS_DIR/zlib/zconf.h"
|
||||
|
||||
echo "All done!"
|
||||
echo ""
|
||||
|
||||
Reference in new issue
Block a user