From adc5d32f474595aa16a90369393440a0bc190777 Mon Sep 17 00:00:00 2001 From: Niyas Sait Date: Mon, 27 Sep 2021 20:52:54 +0100 Subject: Select correct tool platform when building on Windows ARM64 natively (GH-28491) --- PCbuild/pcbuild.proj | 7 ++++--- Tools/scripts/freeze_modules.py | 6 +++++- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/PCbuild/pcbuild.proj b/PCbuild/pcbuild.proj index b3cbd47..f32422a 100644 --- a/PCbuild/pcbuild.proj +++ b/PCbuild/pcbuild.proj @@ -1,5 +1,8 @@  + + + {CC9B93A2-439D-4058-9D29-6DCF43774405} Win32 @@ -15,9 +18,7 @@ - $(Platform) - Win32 - x64 + $(PreferredToolArchitecture) $(Configuration) Release diff --git a/Tools/scripts/freeze_modules.py b/Tools/scripts/freeze_modules.py index aa799d7..cfc6f79 100644 --- a/Tools/scripts/freeze_modules.py +++ b/Tools/scripts/freeze_modules.py @@ -8,6 +8,7 @@ import hashlib import os import ntpath import posixpath +import platform import subprocess import sys import textwrap @@ -35,7 +36,10 @@ if sys.platform != "win32": sys.exit("ERROR: missing _freeze_module") else: def find_tool(): - for arch in ['amd64', 'win32']: + archs = ['amd64', 'win32'] + if platform.machine() == "ARM64": + archs.append('arm64') + for arch in archs: for exe in ['_freeze_module.exe', '_freeze_module_d.exe']: tool = os.path.join(ROOT_DIR, 'PCbuild', arch, exe) if os.path.isfile(tool): -- cgit v0.12