aboutsummaryrefslogtreecommitdiffstats
path: root/support/make
diff options
context:
space:
mode:
Diffstat (limited to 'support/make')
-rw-r--r--support/make/build-rules.mk22
1 files changed, 12 insertions, 10 deletions
diff --git a/support/make/build-rules.mk b/support/make/build-rules.mk
index f852cab..7c918d8 100644
--- a/support/make/build-rules.mk
+++ b/support/make/build-rules.mk
@@ -1,14 +1,16 @@
# Useful tools
-CC := arm-none-eabi-gcc
-CXX := arm-none-eabi-g++
-LD := arm-none-eabi-ld -v
-AR := arm-none-eabi-ar
-AS := arm-none-eabi-gcc
-OBJCOPY := arm-none-eabi-objcopy
-DISAS := arm-none-eabi-objdump
-OBJDUMP := arm-none-eabi-objdump
-SIZE := arm-none-eabi-size
-DFU := dfu-util
+CROSS_COMPILE ?= arm-none-eabi-
+
+CC := $(CROSS_COMPILE)gcc
+CXX := $(CROSS_COMPILE)g++
+LD := $(CROSS_COMPILE)ld -v
+AR := $(CROSS_COMPILE)ar
+AS := $(CROSS_COMPILE)gcc
+OBJCOPY := $(CROSS_COMPILE)objcopy
+DISAS := $(CROSS_COMPILE)objdump
+OBJDUMP := $(CROSS_COMPILE)objdump
+SIZE := $(CROSS_COMPILE)size
+DFU ?= dfu-util
# Suppress annoying output unless V is set
ifndef V