Skip to content

Commit f8a16c3

Browse files
committed
Switch native builds to Node 22
Node 18 is almost end of life and lacks ESM support needed for Vertex AI support. This includes switching from deprecated Vercel PKG to an actively maintained fork (yao-pkg).
1 parent d36ea9b commit f8a16c3

File tree

6 files changed

+86
-313
lines changed

6 files changed

+86
-313
lines changed

packages/cli/bin/build-native

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ ARGS="--config package.json --compress GZip"
1313
if [ -n "${OS}" ]; then
1414
ARCH="${2:-x64}"
1515
echo "Building native binaries for ${OS} ${ARCH}..."
16-
ARGS="${ARGS} -o release/appmap-${OS}-${ARCH} -t node18-${OS}-${ARCH}"
16+
ARGS="${ARGS} -o release/appmap-${OS}-${ARCH} -t node22-${OS}-${ARCH}"
1717
else
1818
echo "Building native binaries for each target..."
1919
fi

packages/cli/package.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@
5454
"@types/validator": "^13.7.10",
5555
"@types/w3c-xmlserializer": "^2.0.2",
5656
"@types/yargs": "^17.0.2",
57+
"@yao-pkg/pkg": "^5.15.0",
5758
"esbuild": "0.19.8",
5859
"eslint": "^8.56.0",
5960
"eslint-config-prettier": "^8.3.0",
@@ -134,7 +135,6 @@
134135
"openapi-types": "^12.1.3",
135136
"ora": "^5.4.1",
136137
"parse-diff": "^0.11.1",
137-
"pkg": "^5.8.1",
138138
"port-pid": "^0.0.7",
139139
"pretty-bytes": "^5.6.0",
140140
"ps-node": "^0.1.6",
@@ -148,10 +148,10 @@
148148
},
149149
"pkg": {
150150
"targets": [
151-
"node18-linux-x64",
152-
"node18-win-x64",
153-
"node18-macos-x64",
154-
"node18-macos-arm64"
151+
"node22-linux-x64",
152+
"node22-win-x64",
153+
"node22-macos-x64",
154+
"node22-macos-arm64"
155155
],
156156
"scripts": [
157157
"built/cmds/record/state/record_*.js",

packages/cli/tests/binary/helpers/setup.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ export default async function performSetup() {
4646
'-o',
4747
'release/appmap',
4848
'-t',
49-
`node18-${platform()}-x64`,
49+
`node22-${platform()}-x64`,
5050
'built/cli.js',
5151
],
5252
packageRoot,

packages/scanner/bin/build-native

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ ARGS="--config package.json --compress GZip"
1313
if [ -n "${OS}" ]; then
1414
ARCH="${2:-x64}"
1515
echo "Building native binaries for ${OS} ${ARCH}..."
16-
ARGS="${ARGS} -o release/scanner-${OS}-${ARCH} -t node18-${OS}-${ARCH}"
16+
ARGS="${ARGS} -o release/scanner-${OS}-${ARCH} -t node22-${OS}-${ARCH}"
1717
else
1818
echo "Building native binaries for each target..."
1919
fi

packages/scanner/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@
4343
"@types/yargs": "^17.0.2",
4444
"@typescript-eslint/eslint-plugin": "^4.30.0",
4545
"@typescript-eslint/parser": "^4.30.0",
46+
"@yao-pkg/pkg": "^5.15.0",
4647
"eslint": "^7.32.0",
4748
"eslint-config-prettier": "^8.3.0",
4849
"eslint-plugin-node": "^11.1.0",
@@ -51,7 +52,6 @@
5152
"jest": "^29.5.0",
5253
"nock": "^13.2.2",
5354
"openapi-types": "^9.3.0",
54-
"pkg": "^5.8.0",
5555
"prettier": "^2.7.1",
5656
"semantic-release": "^19.0.2",
5757
"sinon": "^13.0.1",

0 commit comments

Comments
 (0)