From e6f889c120f65bb3d612aec8e6b1e7e4fcd25378 Mon Sep 17 00:00:00 2001 From: Jon Kunkee Date: Mon, 12 Nov 2018 13:40:56 -0800 Subject: [PATCH] Add ARM64 Windows to configure scripts In order to correctly configure for Windows 10 on ARM, this change adds a --target value arm64-win64-vs15 to ./configure and adds feature enable/disable logic for the new platform. This is merely sufficient for Chromium targeting ARM64 Windows. Bug: 893460 Change-Id: I46194286f63104bdf6ac57d719fdf1e5d5fa72c8 --- README | 1 + build/make/configure.sh | 35 +++++++++++++++++++++++------------ configure | 1 + 3 files changed, 25 insertions(+), 12 deletions(-) diff --git a/README b/README index 49407ed9f..4e8bba0d6 100644 --- a/README +++ b/README @@ -63,6 +63,7 @@ COMPILING THE APPLICATIONS/LIBRARIES: arm64-android-gcc arm64-darwin-gcc arm64-linux-gcc + arm64-win64-vs15 armv7-android-gcc armv7-darwin-gcc armv7-linux-rvct diff --git a/build/make/configure.sh b/build/make/configure.sh index fdda759be..179359e5d 100644 --- a/build/make/configure.sh +++ b/build/make/configure.sh @@ -1010,18 +1010,29 @@ EOF fi ;; vs*) - asm_conversion_cmd="${source_path}/build/make/ads2armasm_ms.pl" - AS_SFX=.S - msvs_arch_dir=arm-msvs - disable_feature multithread - disable_feature unit_tests - vs_version=${tgt_cc##vs} - if [ $vs_version -ge 12 ]; then - # MSVC 2013 doesn't allow doing plain .exe projects for ARM, - # only "AppContainerApplication" which requires an AppxManifest. - # Therefore disable the examples, just build the library. - disable_feature examples - disable_feature tools + # A number of ARM-based Windows platforms are constrained by their + # respective SDKs' limitations. Fortunately, these are all 32-bit ABIs + # and so can be selected as 'win32'. + if [ ${tgt_os} = "win32" ]; then + asm_conversion_cmd="${source_path}/build/make/ads2armasm_ms.pl" + AS_SFX=.S + msvs_arch_dir=arm-msvs + disable_feature multithread + disable_feature unit_tests + vs_version=${tgt_cc##vs} + if [ $vs_version -ge 12 ]; then + # MSVC 2013 doesn't allow doing plain .exe projects for ARM32, + # only "AppContainerApplication" which requires an AppxManifest. + # Therefore disable the examples, just build the library. + disable_feature examples + disable_feature tools + fi + #else + # Windows 10 on ARM, on the other hand, has full Windows SDK support + # for building Win32 ARM64 applications in addition to ARM64 + # Windows Store apps. It is the only 64-bit ARM ABI that + # Windows supports, so it is the default definition of 'win64'. + # ARM64 build support officially shipped in Visual Studio 15.9.0. fi ;; rvct) diff --git a/configure b/configure index e864e57fb..966fedba4 100755 --- a/configure +++ b/configure @@ -102,6 +102,7 @@ all_platforms="${all_platforms} arm64-android-gcc" all_platforms="${all_platforms} arm64-darwin-gcc" all_platforms="${all_platforms} arm64-linux-gcc" all_platforms="${all_platforms} arm64-win64-gcc" +all_platforms="${all_platforms} arm64-win64-vs15" all_platforms="${all_platforms} armv7-android-gcc" #neon Cortex-A8 all_platforms="${all_platforms} armv7-darwin-gcc" #neon Cortex-A8 all_platforms="${all_platforms} armv7-linux-rvct" #neon Cortex-A8 -- 2.40.0