Сборка для linux-arm64

This commit is contained in:
Book Pauk
2022-12-06 16:15:28 +07:00
parent c2c88cb397
commit a4715be0ed
4 changed files with 7 additions and 3 deletions

View File

@@ -287,6 +287,8 @@ sudo service nginx reload
Сборка только в среде Linux.
Необходима версия node.js не ниже 16.
Для сборки linux-arm64 необходимо предварительно установить [QEMU](https://wiki.debian.org/QemuUserEmulation).
```sh
git clone https://github.com/bookpauk/inpx-web
cd inpx-web

View File

@@ -12,8 +12,8 @@ const publicDir = `${tmpDir}/public`;
const outDir = `${distDir}/${platform}`;
async function build() {
if (platform != 'linux' && platform != 'win' && platform != 'macos')
throw new Error(`Unknown platform: ${platform}`);
if (!platform)
throw new Error(`Please set platform`);
await fs.emptyDir(outDir);

View File

@@ -22,6 +22,7 @@ async function main() {
await fs.emptyDir(outDir);
await makeRelease('win');
await makeRelease('linux');
await makeRelease('linux-arm64');
await makeRelease('macos');
} catch(e) {
console.error(e);

View File

@@ -11,10 +11,11 @@
"dev": "nodemon --inspect --ignore server/.inpx-web --ignore client --exec 'node --expose-gc server --lib-dir=server/.inpx-web/lib'",
"build:client": "webpack --config build/webpack.prod.config.js",
"build:linux": "npm run build:client && node build/prepkg.js linux && pkg -t node16-linux-x64 -C GZip --options max-old-space-size=4096,expose-gc -o dist/linux/inpx-web .",
"build:linux-arm64": "npm run build:client && node build/prepkg.js linux-arm64 && pkg -t node16-linuxstatic-arm64 -C GZip --options max-old-space-size=4096,expose-gc -o dist/linux-arm64/inpx-web .",
"build:win": "npm run build:client && node build/prepkg.js win && pkg -t node16-win-x64 -C GZip --options max-old-space-size=4096,expose-gc -o dist/win/inpx-web .",
"build:macos": "npm run build:client && node build/prepkg.js macos && pkg -t node16-macos-x64 -C GZip --options max-old-space-size=4096,expose-gc -o dist/macos/inpx-web .",
"build:client-dev": "webpack --config build/webpack.dev.config.js",
"build:all": "npm run build:linux && npm run build:win && npm run build:macos",
"build:all": "npm run build:linux && npm run build:win && npm run build:macos && npm run build:linux-arm64",
"release": "npm run build:all && node build/release.js",
"postinstall": "npm run build:client-dev"
},