Skip to content

Commit

Permalink
setuptools.msvc: set host_dir correctly on ARM64 hosts
Browse files Browse the repository at this point in the history
  • Loading branch information
swt2c committed Jan 5, 2025
1 parent 53d5ac2 commit b8f9800
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions setuptools/msvc.py
Original file line number Diff line number Diff line change
Expand Up @@ -1038,9 +1038,12 @@ def VCTools(self):
tools += [os.path.join(si.VCInstallDir, path)]

elif self.vs_ver >= 15.0:
host_dir = (
r'bin\HostX86%s' if self.pi.current_is_x86() else r'bin\HostX64%s'
)
if self.pi.current_cpu in ('x86', 'arm64'):
host_id = self.pi.current_cpu.upper()
else:
host_id = 'X64'
host_dir = os.path.join('bin', f'Host{host_id}%s')

tools += [
os.path.join(si.VCInstallDir, host_dir % self.pi.target_dir(x64=True))
]
Expand Down

0 comments on commit b8f9800

Please sign in to comment.