You've already forked joplin
mirror of
https://github.com/laurent22/joplin.git
synced 2025-07-13 00:10:37 +02:00
Co-authored-by: Laurent Cozic <laurent22@users.noreply.github.com>
This commit is contained in:
@ -1,5 +1,9 @@
|
|||||||
const execCommand = require('./execCommand');
|
const execCommand = require('./execCommand');
|
||||||
|
|
||||||
|
const isArm64 = () => {
|
||||||
|
return process.platform === 'arm64';
|
||||||
|
};
|
||||||
|
|
||||||
const isWindows = () => {
|
const isWindows = () => {
|
||||||
return process && process.platform === 'win32';
|
return process && process.platform === 'win32';
|
||||||
};
|
};
|
||||||
@ -28,6 +32,13 @@ async function main() {
|
|||||||
// with 32-bit files and vice-versa
|
// with 32-bit files and vice-versa
|
||||||
console.info(await execCommand(['yarn', 'run', 'electron-rebuild', forceAbiArgs, '--arch ia32'].join(' ')));
|
console.info(await execCommand(['yarn', 'run', 'electron-rebuild', forceAbiArgs, '--arch ia32'].join(' ')));
|
||||||
console.info(await execCommand(['yarn', 'run', 'electron-rebuild', forceAbiArgs, '--arch x64'].join(' ')));
|
console.info(await execCommand(['yarn', 'run', 'electron-rebuild', forceAbiArgs, '--arch x64'].join(' ')));
|
||||||
|
} else if (isArm64()) {
|
||||||
|
// Keytar needs it's own electron-rebuild or else it will not fetch the
|
||||||
|
// existing prebuilt binary, this will cause cross-compilation to fail.
|
||||||
|
// E.g. for MacOS arm64 it will download:
|
||||||
|
// https://github.com/atom/node-keytar/releases/download/v7.9.0/keytar-v7.9.0-napi-v3-darwin-arm64.tar.gz
|
||||||
|
console.info(await execCommand(['yarn', 'run', 'electron-rebuild', forceAbiArgs, '--arch=arm64', '--only=keytar'].join(' ')));
|
||||||
|
console.info(await execCommand(['yarn', 'run', 'electron-rebuild', forceAbiArgs].join(' ')));
|
||||||
} else {
|
} else {
|
||||||
console.info(await execCommand(['yarn', 'run', 'electron-rebuild', forceAbiArgs].join(' ')));
|
console.info(await execCommand(['yarn', 'run', 'electron-rebuild', forceAbiArgs].join(' ')));
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user