Skip to content

Commit

Permalink
fix platform conversion
Browse files Browse the repository at this point in the history
  • Loading branch information
Simon-Laux committed May 10, 2024
1 parent f98c0af commit 5eff575
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ def convert_cpu_arch_to_npm_cpu_arch(arch):
return "i32"
if arch == "aarch64":
return "arm64"
if arch == "armv7" or arch == "arm":
return "arm"
print("architecture might not be known by nodejs, please make sure it can be returned by 'process.arch':", arch)
return arch

Expand All @@ -13,5 +15,7 @@ def convert_os_to_npm_os(os):
return "win32"
if os == "darwin" or os == "linux":
return os
if os.startswith("android"):
return "android"
print("architecture might not be known by nodejs, please make sure it can be returned by 'process.platform':", os)
return os

0 comments on commit 5eff575

Please sign in to comment.