Skip to content

Commit b2c7790

Browse files
committed
[nrf noup] Use proper ZAP package for Linux/Windows with ARM CPUs
Currently x86 ZAP is always downloaded on Linux/Windows. This change looks at the architecture of the system to download either x86_64 or arm64 binaries as provided by ZAP releases Signed-off-by: Kendall Goto <kendall@level.co>
1 parent 0539fd4 commit b2c7790

1 file changed

Lines changed: 8 additions & 2 deletions

File tree

scripts/west/zap_common.py

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -132,12 +132,18 @@ def unzip(zip: Path, out: Path):
132132
f.close()
133133

134134
if self.current_os == 'Linux':
135-
self.package = 'zap-linux-x64'
135+
if platform.machine() == 'aarch64':
136+
self.package = 'zap-linux-arm64'
137+
else:
138+
self.package = 'zap-linux-x64'
136139
self.zap_exe = 'zap'
137140
self.zap_cli_exe = 'zap-cli'
138141
self.unzip = unzip
139142
elif self.current_os == 'Windows':
140-
self.package = 'zap-win-x64'
143+
if platform.machine() == 'ARM64':
144+
self.package = 'zap-win-arm64'
145+
else:
146+
self.package = 'zap-win-x64'
141147
self.zap_exe = 'zap.exe'
142148
self.zap_cli_exe = 'zap-cli.exe'
143149
self.unzip = unzip

0 commit comments

Comments
 (0)