cmake: compiler: arm: Fold fpu-for-gcc-m-cpu.cmake into target.cmake
We only use fpu-for-gcc-m-cpu.cmake once, so just fold it into where it used. Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
This commit is contained in:
parent
8bc76b0480
commit
8fb15826ff
2 changed files with 11 additions and 14 deletions
|
@ -52,7 +52,17 @@ if("${ARCH}" STREQUAL "arm")
|
|||
-mcpu=${GCC_M_CPU}
|
||||
)
|
||||
|
||||
include(${ZEPHYR_BASE}/cmake/fpu-for-gcc-m-cpu.cmake)
|
||||
# Defines a mapping from GCC_M_CPU to FPU
|
||||
|
||||
if(CONFIG_CPU_HAS_FPU_DOUBLE_PRECISION)
|
||||
set(PRECISION_TOKEN)
|
||||
else()
|
||||
set(PRECISION_TOKEN sp-)
|
||||
endif()
|
||||
|
||||
set(FPU_FOR_cortex-m4 fpv4-${PRECISION_TOKEN}d16)
|
||||
set(FPU_FOR_cortex-m7 fpv5-${PRECISION_TOKEN}d16)
|
||||
set(FPU_FOR_cortex-m33 fpv5-${PRECISION_TOKEN}d16)
|
||||
|
||||
if(CONFIG_FLOAT)
|
||||
list(APPEND TOOLCHAIN_C_FLAGS -mfpu=${FPU_FOR_${GCC_M_CPU}})
|
||||
|
|
|
@ -1,13 +0,0 @@
|
|||
# SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
# Defines a mapping from GCC_M_CPU to FPU
|
||||
|
||||
if(CONFIG_CPU_HAS_FPU_DOUBLE_PRECISION)
|
||||
set(PRECISION_TOKEN)
|
||||
else()
|
||||
set(PRECISION_TOKEN sp-)
|
||||
endif()
|
||||
|
||||
set(FPU_FOR_cortex-m4 fpv4-${PRECISION_TOKEN}d16)
|
||||
set(FPU_FOR_cortex-m7 fpv5-${PRECISION_TOKEN}d16)
|
||||
set(FPU_FOR_cortex-m33 fpv5-${PRECISION_TOKEN}d16)
|
Loading…
Add table
Add a link
Reference in a new issue