Skip to content

Commit

Permalink
i#1569 AArch64: Handle AArch64 in runsuite_common_pre.cmake.
Browse files Browse the repository at this point in the history
On AArch64 we set ARCH_IS_X86 to OFF, and KERNEL_IS_X64 to ON,
and we skip 32-bit builds.

Review-URL: https://codereview.appspot.com/310170043
  • Loading branch information
egrimley-arm committed Sep 15, 2016
1 parent cb0403d commit 26025a5
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions suite/runsuite_common_pre.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -283,7 +283,7 @@ set(CTEST_CUSTOM_MAXIMUM_NUMBER_OF_WARNINGS 200)

# Detect if the arch is x86
if (NOT DEFINED ARCH_IS_X86)
if (CMAKE_SYSTEM_PROCESSOR MATCHES "arm")
if (CMAKE_SYSTEM_PROCESSOR MATCHES "^(arm|aarch64)")
set(ARCH_IS_X86 OFF)
else ()
set(ARCH_IS_X86 ON)
Expand Down Expand Up @@ -311,7 +311,7 @@ if (NOT DEFINED KERNEL_IS_X64) # Allow variable override.
RESULT_VARIABLE cmd_result)
# If for some reason uname fails (not on PATH), assume the kernel is x64
# anyway.
if (cmd_result OR "${machine}" MATCHES "x86_64")
if (cmd_result OR "${machine}" MATCHES "x86_64|aarch64")
set(KERNEL_IS_X64 ON)
else ()
set(KERNEL_IS_X64 OFF)
Expand Down Expand Up @@ -406,6 +406,11 @@ function(testbuild_ex name is64 initial_cache test_only_in_long
return()
endif ()

# Skip 32-bit builds on an AArch64 machine.
if (NOT is64 AND CMAKE_SYSTEM_PROCESSOR MATCHES "^aarch64")
return()
endif ()

if (NOT arg_use_nmake AND NOT arg_use_make AND NOT arg_use_ninja)
# we need a separate generator for 64-bit as well as the PATH
# env var changes below (since we run cl directly)
Expand Down

0 comments on commit 26025a5

Please sign in to comment.