aboutsummaryrefslogtreecommitdiffstats
path: root/firmware
diff options
context:
space:
mode:
Diffstat (limited to 'firmware')
-rw-r--r--firmware/Makefile13
-rw-r--r--firmware/Makefile.dfu13
2 files changed, 14 insertions, 12 deletions
diff --git a/firmware/Makefile b/firmware/Makefile
index 350b0dc..1581a1f 100644
--- a/firmware/Makefile
+++ b/firmware/Makefile
@@ -352,12 +352,13 @@ LPC21ISP_CONTROL = -control
# Define programs and commands.
SHELL = sh
-CC = arm-elf-gcc
-CPP = arm-elf-g++
-OBJCOPY = arm-elf-objcopy
-OBJDUMP = arm-elf-objdump
-SIZE = arm-elf-size
-NM = arm-elf-nm
+CROSS_COMPILE ?= arm-elf-
+CC = $(CROSS_COMPILE)gcc
+CPP = $(CROSS_COMPILE)g++
+OBJCOPY = $(CROSS_COMPILE)objcopy
+OBJDUMP = $(CROSS_COMPILE)objdump
+SIZE = $(CROSS_COMPILE)size
+NM = $(CROSS_COMPILE)nm
REMOVE = rm -f
COPY = cp
diff --git a/firmware/Makefile.dfu b/firmware/Makefile.dfu
index 3c797ef..1e9e71c 100644
--- a/firmware/Makefile.dfu
+++ b/firmware/Makefile.dfu
@@ -303,12 +303,13 @@ LPC21ISP_CONTROL = -control
# Define programs and commands.
SHELL = sh
-CC = arm-elf-gcc
-CPP = arm-elf-g++
-OBJCOPY = arm-elf-objcopy
-OBJDUMP = arm-elf-objdump
-SIZE = arm-elf-size
-NM = arm-elf-nm
+CROSS_COMPILE ?= arm-elf-
+CC = $(CROSS_COMPILE)gcc
+CPP = $(CROSS_COMPILE)g++
+OBJCOPY = $(CROSS_COMPILE)objcopy
+OBJDUMP = $(CROSS_COMPILE)objdump
+SIZE = $(CROSS_COMPILE)size
+NM = $(CROSS_COMPILE)nm
REMOVE = rm -f
COPY = cp