diff --git a/cli/src/create-npm-dir.ts b/cli/src/create-npm-dir.ts index 86b326e8..b4e12c85 100644 --- a/cli/src/create-npm-dir.ts +++ b/cli/src/create-npm-dir.ts @@ -47,7 +47,10 @@ export class CreateNpmDirCommand extends Command { name: `${packageName}-${platformDetail.platformArchABI}`, version, os: [platformDetail.platform], - cpu: [platformDetail.arch], + cpu: + platformDetail.arch !== 'universal' + ? [platformDetail.arch] + : undefined, main: binaryFileName, files: [binaryFileName], ...pick( diff --git a/cli/src/new/index.ts b/cli/src/new/index.ts index c4cb9b51..a4fc587b 100644 --- a/cli/src/new/index.ts +++ b/cli/src/new/index.ts @@ -45,6 +45,7 @@ const SupportedPlatforms: string[] = [ 'x86_64-unknown-freebsd', 'i686-pc-windows-msvc', 'armv7-linux-androideabi', + 'universal-apple-darwin', ] export class NewProjectCommand extends Command { diff --git a/cli/src/parse-triple.ts b/cli/src/parse-triple.ts index 4368ca28..fef1372c 100644 --- a/cli/src/parse-triple.ts +++ b/cli/src/parse-triple.ts @@ -13,6 +13,7 @@ type NodeJSArch = | 's390x' | 'x32' | 'x64' + | 'universal' const CpuToNodeArch: { [index: string]: NodeJSArch } = { x86_64: 'x64',