aboutsummaryrefslogtreecommitdiffstats
path: root/LUFA/Build/DMBS/DMBS/gcc.mk
diff options
context:
space:
mode:
authorDean Camera <dean@fourwalledcubicle.com>2016-04-03 11:35:25 +1000
committerDean Camera <dean@fourwalledcubicle.com>2016-04-03 11:35:25 +1000
commit3069b7d9d2a01f7f1e68722e722fa8e868154585 (patch)
tree6974559aae8c614e6c748f5b2d5e04ed0561ae5a /LUFA/Build/DMBS/DMBS/gcc.mk
parent9cca7a594f23f46d56ded6ab806235e3fc62055d (diff)
downloadlufa-3069b7d9d2a01f7f1e68722e722fa8e868154585.tar.gz
lufa-3069b7d9d2a01f7f1e68722e722fa8e868154585.tar.bz2
lufa-3069b7d9d2a01f7f1e68722e722fa8e868154585.zip
Update to latest DMBS version.
Diffstat (limited to 'LUFA/Build/DMBS/DMBS/gcc.mk')
-rw-r--r--LUFA/Build/DMBS/DMBS/gcc.mk6
1 files changed, 6 insertions, 0 deletions
diff --git a/LUFA/Build/DMBS/DMBS/gcc.mk b/LUFA/Build/DMBS/DMBS/gcc.mk
index b9347a60b..f3c695502 100644
--- a/LUFA/Build/DMBS/DMBS/gcc.mk
+++ b/LUFA/Build/DMBS/DMBS/gcc.mk
@@ -192,6 +192,12 @@ BASE_C_FLAGS := -x c -O$(OPTIMIZATION) -std=$(C_STANDARD) -Wstrict-prototypes
BASE_CPP_FLAGS := -x c++ -O$(OPTIMIZATION) -std=$(CPP_STANDARD)
BASE_ASM_FLAGS := -x assembler-with-cpp
+# This flag is required for bootloaders as GCC will emit invalid jump table
+# assembly code for devices with large amounts of flash; the jump table target
+# is extracted from FLASH without using the correct ELPM instruction, resulting
+# in a pseudo-random jump target.
+BASE_CC_FLAGS += -fno-jump-tables
+
# Create a list of flags to pass to the linker
BASE_LD_FLAGS := -lm -Wl,-Map=$(TARGET).map,--cref -Wl,--gc-sections
ifeq ($(LINKER_RELAXATIONS), Y)