diff options
-rw-r--r-- | config/arch/arm.in | 25 | ||||
-rw-r--r-- | scripts/build/arch/arm.sh | 10 |
2 files changed, 35 insertions, 0 deletions
diff --git a/config/arch/arm.in b/config/arch/arm.in index dc31a5cf..4dc2eafb 100644 --- a/config/arch/arm.in +++ b/config/arch/arm.in @@ -13,6 +13,31 @@ config ARCH_arm The ARM architecture, as defined by: http://www.arm.com/ +config ARCH_ARM_MODE + string + default "arm" if ARCH_ARM_MODE_ARM + default "thumb" if ARCH_ARM_MODE_THUMB + +choice + bool + prompt "Default instruction set mode" + default ARCH_ARM_MODE_ARM + +config ARCH_ARM_MODE_ARM + bool + prompt "arm" + help + Defaults to emitting instructions in the ARM mode. + +config ARCH_ARM_MODE_THUMB + bool + prompt "thumb (EXPERIMENTAL)" + depends on EXPERIMENTAL + help + Defaults to emitting instructions in the THUMB mode. + +endchoice + config ARCH_ARM_EABI bool prompt "Use EABI" diff --git a/scripts/build/arch/arm.sh b/scripts/build/arch/arm.sh index a394cc76..961253f6 100644 --- a/scripts/build/arch/arm.sh +++ b/scripts/build/arch/arm.sh @@ -10,4 +10,14 @@ CT_DoArchTupleValues() { uClibc,y) CT_TARGET_SYS=uclibcgnueabi;; *,y) CT_TARGET_SYS=eabi;; esac + + # Set the default instrcution set mode + case "${CT_ARCH_ARM_MODE}" in + arm) ;; + thumb) + CT_ARCH_CC_CORE_EXTRA_CONFIG="--with-mode=thumb" + CT_ARCH_CC_EXTRA_CONFIG="--with-mode=thumb" +# CT_ARCH_TARGET_CFLAGS="-mthumb" + ;; + esac } |