Skip to content

Commit 49f760a

Browse files
committed
fix: use Node 20.19.5 ARMv7 binary from pkg-binaries
The previous attempt failed because: 1. Downloaded from wrong repo (pkg-fetch instead of pkg-binaries) 2. Used wrong version (v20.10.0 doesn't exist for ARMv7) 3. Used wrong filename format (built- vs fetched-) Solution: - Download Node 20.19.5 ARMv7 binary from yao-pkg/pkg-binaries - Use correct cache filename: fetched-v20.19.5-linux-armv7 - Explicitly target node20.19.5-linux-armv7 in build command - Updated both workflow and package.json This binary is the latest ARMv7 build available (~47MB) and will be used from cache instead of attempting cross-compilation.
1 parent 5a88230 commit 49f760a

2 files changed

Lines changed: 13 additions & 8 deletions

File tree

.github/workflows/release.yml

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -91,15 +91,15 @@ jobs:
9191
# Create pkg cache directory (v3.5 is the pkg-fetch cache version)
9292
mkdir -p ~/.pkg-cache/v3.5
9393
94-
# Download pre-built ARMv7 binary from yao-pkg/pkg-fetch releases
95-
# Using node20.10.0 which has confirmed armv7 support
96-
curl -L -o ~/.pkg-cache/v3.5/built-v20.10.0-linuxstatic-armv7 \
97-
https://github.com/yao-pkg/pkg-fetch/releases/download/node20/built-v20.10.0-linuxstatic-armv7
94+
# Download pre-built ARMv7 binary from yao-pkg/pkg-binaries
95+
# Using node 20.19.5 (latest available ARMv7 build, ~47MB)
96+
curl -L -o ~/.pkg-cache/v3.5/fetched-v20.19.5-linux-armv7 \
97+
https://github.com/yao-pkg/pkg-binaries/releases/download/node20/node-v20.19.5-linux-armv7
9898
9999
# Make executable
100-
chmod +x ~/.pkg-cache/v3.5/built-v20.10.0-linuxstatic-armv7
100+
chmod +x ~/.pkg-cache/v3.5/fetched-v20.19.5-linux-armv7
101101
102-
# Verify download
102+
# Verify download (should be ~47MB)
103103
ls -lh ~/.pkg-cache/v3.5/
104104
echo "ARMv7 binary cached successfully"
105105
@@ -127,7 +127,12 @@ jobs:
127127
elif [[ "${{ matrix.platform }}" == "mac" ]]; then
128128
npx @yao-pkg/pkg . --targets node20-macos-${{ matrix.arch }} --output dist/${{ matrix.output }}
129129
elif [[ "${{ matrix.platform }}" == "linux" ]]; then
130-
npx @yao-pkg/pkg . --targets node20-linux-${{ matrix.arch }} --output dist/${{ matrix.output }}
130+
# Special case: ARMv7 requires explicit version (20.19.5 from pkg-binaries)
131+
if [[ "${{ matrix.arch }}" == "armv7" ]]; then
132+
npx @yao-pkg/pkg . --targets node20.19.5-linux-armv7 --output dist/${{ matrix.output }}
133+
else
134+
npx @yao-pkg/pkg . --targets node20-linux-${{ matrix.arch }} --output dist/${{ matrix.output }}
135+
fi
131136
fi
132137
133138
- name: Upload Build Artifacts

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
"build:webui:copy": "node scripts/copy-webui-assets.js",
1919
"build:linux": "npm run build && yao-pkg . --targets node20-linux-x64 --output dist/flashforge-webui-linux-x64",
2020
"build:linux-arm": "npm run build && yao-pkg . --targets node20-linux-arm64 --output dist/flashforge-webui-linux-arm64",
21-
"build:linux-armv7": "npm run build && yao-pkg . --targets node20-linux-armv7 --output dist/flashforge-webui-linux-armv7",
21+
"build:linux-armv7": "npm run build && yao-pkg . --targets node20.19.5-linux-armv7 --output dist/flashforge-webui-linux-armv7",
2222
"build:win": "npm run build && yao-pkg . --targets node20-win-x64 --output dist/flashforge-webui-win-x64.exe",
2323
"build:mac": "npm run build && yao-pkg . --targets node20-macos-x64 --output dist/flashforge-webui-macos-x64",
2424
"build:mac-arm": "npm run build && yao-pkg . --targets node20-macos-arm64 --output dist/flashforge-webui-macos-arm64",

0 commit comments

Comments
 (0)