Skip to content

Commit

Permalink
fix: Deno.build.arch should be aarch64 for aarch64 (#177)
Browse files Browse the repository at this point in the history
  • Loading branch information
dsherret authored Feb 4, 2024
1 parent ed765fb commit c43f414
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions packages/shim-deno/src/deno/stable/variables/build.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,18 @@

import * as os from "os";

const arch = process.arch === "arm64" ? "aarch64" : "x86_64";
export const build: typeof Deno.build = {
arch: "x86_64",
arch,
os: ((p) => p === "win32" ? "windows" : p === "darwin" ? "darwin" : "linux")(
os.platform(),
),
vendor: "pc",
target:
((p) =>
p === "win32"
? "x86_64-pc-windows-msvc"
? `${arch}-pc-windows-msvc`
: p === "darwin"
? "x86_64-apple-darwin"
: "x86_64-unknown-linux-gnu")(os.platform()),
? `${arch}-apple-darwin`
: `${arch}-unknown-linux-gnu`)(os.platform()),
};

0 comments on commit c43f414

Please sign in to comment.