drop compilation of x86 binaries
This commit is contained in:
parent
920d3f9c9c
commit
ff942655fa
@ -11,22 +11,17 @@ import { version } from '../package.json';
|
||||
const cloud = new Cloud({ owner: 'zeit', repo: 'pkg-fetch' });
|
||||
|
||||
export function dontBuild (nodeVersion, targetPlatform, targetArch) {
|
||||
// binaries are not provided for x86 anymore
|
||||
if (targetArch === 'x86') return true;
|
||||
// https://support.apple.com/en-us/HT201948
|
||||
// don't disable macos-x86 because it is not possible
|
||||
// to cross-compile for x86 from macos otherwise
|
||||
const major = nodeVersion.match(/^v?(\d+)/)[1] | 0;
|
||||
// node 0.12 does not compile on arm
|
||||
if (/^arm/.test(targetArch) &&
|
||||
major === 0) return true;
|
||||
// obstacles on freebsd x86 for node4
|
||||
if (targetPlatform === 'freebsd' &&
|
||||
targetArch === 'x86' &&
|
||||
major < 6) return true;
|
||||
if (targetPlatform === 'freebsd' &&
|
||||
major < 4) return true;
|
||||
if (/^arm/.test(targetArch) && major === 0) return true;
|
||||
if (targetPlatform === 'freebsd' && major < 4) return true;
|
||||
if (targetPlatform === 'alpine' &&
|
||||
(targetArch !== 'x64' ||
|
||||
major < 6)) return true;
|
||||
(targetArch !== 'x64' || major < 6)) return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user