mirror of
https://github.com/apache/nuttx.git
synced 2026-05-31 23:40:19 +08:00
arch/arm: move -mthumb option back to ARCHCPUFLAGS
CONFIG_ARM_TOOLCHAIN_GNU_EABI build got broken when -mthumb option was moved from ARCHCPUFLAGS to ARCHOPTIMIZATION variable: arm-none-eabi-ld: error: .../build/nuttx/nuttx uses VFP register arguments, /usr/lib/gcc/arm-none-eabi/5.4.1/libgcc.a(_fixunsdfdi.o) does not arm-none-eabi-ld: failed to merge target specific data of file /usr/lib/gcc/arm-none-eabi/5.4.1/libgcc.a(_fixunsdfdi.o) arm-none-eabi-ld: error: .../build/nuttx/nuttx uses VFP register arguments, /usr/lib/gcc/arm-none-eabi/5.4.1/libgcc.a(_udivmoddi4.o) does not arm-none-eabi-ld: failed to merge target specific data of file /usr/lib/gcc/arm-none-eabi/5.4.1/libgcc.a(_udivmoddi4.o)
This commit is contained in:
committed by
Xiang Xiao
parent
d4dc0f6ec7
commit
7af151aa51
@@ -74,23 +74,6 @@ ifeq ($(CONFIG_MM_KASAN_ALL),y)
|
|||||||
ARCHOPTIMIZATION += -fsanitize=kernel-address
|
ARCHOPTIMIZATION += -fsanitize=kernel-address
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifeq ($(CONFIG_ARM_THUMB),y)
|
|
||||||
ARCHOPTIMIZATION += -mthumb
|
|
||||||
|
|
||||||
# GCC Manual:
|
|
||||||
# -mthumb
|
|
||||||
# ... If you want to force assembler files to be interpreted as Thumb
|
|
||||||
# code, either add a `.thumb' directive to the source or pass the
|
|
||||||
# -mthumb option directly to the assembler by prefixing it with -Wa.
|
|
||||||
|
|
||||||
ARCHOPTIMIZATION += -Wa,-mthumb
|
|
||||||
|
|
||||||
# Outputs an implicit IT block when there is a conditional instruction
|
|
||||||
# without an enclosing IT block.
|
|
||||||
|
|
||||||
ARCHOPTIMIZATION += -Wa,-mimplicit-it=always
|
|
||||||
endif
|
|
||||||
|
|
||||||
ifeq ($(CONFIG_UNWINDER_ARM),y)
|
ifeq ($(CONFIG_UNWINDER_ARM),y)
|
||||||
ARCHOPTIMIZATION += -funwind-tables -fasynchronous-unwind-tables
|
ARCHOPTIMIZATION += -funwind-tables -fasynchronous-unwind-tables
|
||||||
endif
|
endif
|
||||||
@@ -144,6 +127,23 @@ endif
|
|||||||
|
|
||||||
ARCHCPUFLAGS += $(TOOLCHAIN_MARCH) $(TOOLCHAIN_MTUNE) $(TOOLCHAIN_MFLOAT)
|
ARCHCPUFLAGS += $(TOOLCHAIN_MARCH) $(TOOLCHAIN_MTUNE) $(TOOLCHAIN_MFLOAT)
|
||||||
|
|
||||||
|
ifeq ($(CONFIG_ARM_THUMB),y)
|
||||||
|
ARCHCPUFLAGS += -mthumb
|
||||||
|
|
||||||
|
# GCC Manual:
|
||||||
|
# -mthumb
|
||||||
|
# ... If you want to force assembler files to be interpreted as Thumb
|
||||||
|
# code, either add a `.thumb' directive to the source or pass the
|
||||||
|
# -mthumb option directly to the assembler by prefixing it with -Wa.
|
||||||
|
|
||||||
|
ARCHCPUFLAGS += -Wa,-mthumb
|
||||||
|
|
||||||
|
# Outputs an implicit IT block when there is a conditional instruction
|
||||||
|
# without an enclosing IT block.
|
||||||
|
|
||||||
|
ARCHCPUFLAGS += -Wa,-mimplicit-it=always
|
||||||
|
endif
|
||||||
|
|
||||||
# Clang toolchain
|
# Clang toolchain
|
||||||
|
|
||||||
ifeq ($(CONFIG_ARM_TOOLCHAIN_CLANG),y)
|
ifeq ($(CONFIG_ARM_TOOLCHAIN_CLANG),y)
|
||||||
|
|||||||
Reference in New Issue
Block a user