CMake: Cortex-A: Use MBED_CPU_CORE to set -mcpu

As we're moving away from the use of CMAKE_SYSTEM_PROCESSOR, use
MBED_CPU_CORE instead. They differ in cases, but both GCC and Arm
toolchains support case-insensitive CPU names.
pull/14575/head
Lingkai Dong 2021-07-21 17:25:42 +01:00
parent efaf159ca4
commit 4b6f243963
1 changed files with 2 additions and 2 deletions

View File

@ -8,13 +8,13 @@ if(${MBED_TOOLCHAIN} STREQUAL "GCC_ARM")
"-mfpu=vfpv3"
"-mfloat-abi=softfp"
"-mno-unaligned-access"
"-mcpu=${CMAKE_SYSTEM_PROCESSOR}"
"-mcpu=${MBED_CPU_CORE}"
)
elseif(${MBED_TOOLCHAIN} STREQUAL "ARM")
list(APPEND common_options
"-mfpu=vfpv3"
"-mfloat-abi=hard"
"-mcpu=${CMAKE_SYSTEM_PROCESSOR}"
"-mcpu=${MBED_CPU_CORE}"
)
endif()