aboutsummaryrefslogtreecommitdiff
path: root/scripts/stubs/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/stubs/Makefile')
-rw-r--r--scripts/stubs/Makefile12
1 files changed, 12 insertions, 0 deletions
diff --git a/scripts/stubs/Makefile b/scripts/stubs/Makefile
new file mode 100644
index 0000000..eb588d8
--- /dev/null
+++ b/scripts/stubs/Makefile
@@ -0,0 +1,12 @@
+CROSS_COMPILE = stm32-
+CC = $(CROSS_COMPILE)gcc
+OBJCOPY = $(CROSS_COMPILE)objcopy
+
+all: stm32_opterase.bin stm32_optprog.bin
+
+%.bin: %.S
+ $(CC) -nostdlib -Wl,-Ttext,0x20000000 $<
+ $(OBJCOPY) -O binary a.out $@
+
+clean:
+ -rm *.bin