aboutsummaryrefslogtreecommitdiff
path: root/system-clock/Makefile.preamble
diff options
context:
space:
mode:
authorJosh Rahm <joshuarahm@gmail.com>2018-01-15 14:36:22 -0700
committerJosh Rahm <joshuarahm@gmail.com>2018-01-15 14:38:17 -0700
commit178921510fb527ef294b29b690ec2ac1ac696d8e (patch)
tree1fff6fbe3e2a6823a47a33a148d78f27a20f7ac6 /system-clock/Makefile.preamble
parent8519eb78ecf71da0d121d77265b9b70bc5f70561 (diff)
downloadstm32l4-178921510fb527ef294b29b690ec2ac1ac696d8e.tar.gz
stm32l4-178921510fb527ef294b29b690ec2ac1ac696d8e.tar.bz2
stm32l4-178921510fb527ef294b29b690ec2ac1ac696d8e.zip
update the genmake system to put build files in their own directories
Diffstat (limited to 'system-clock/Makefile.preamble')
-rw-r--r--system-clock/Makefile.preamble10
1 files changed, 5 insertions, 5 deletions
diff --git a/system-clock/Makefile.preamble b/system-clock/Makefile.preamble
index 2a66399..b53a130 100644
--- a/system-clock/Makefile.preamble
+++ b/system-clock/Makefile.preamble
@@ -6,16 +6,16 @@ CFLAGS?=$(OPT) -mcpu=cortex-m4 -mthumb -g -lgcc -static -nostartfiles
LD_FLAGS?=-T linker_script.ld -nostdlib --cref -Map main.map -static
-all: main.elf
+all: _$(PREFIX)_obs/main.elf
-main.bin: main.elf
- $(PREFIX)objcopy -O binary main.elf main.bin
+_$(PREFIX)_obs/main.bin: main.elf
+ $(PREFIX)objcopy -O binary _$(PREFIX)_obs/main.elf _$(PREFIX)_obs/main.bin
flash: main.bin
- st-flash write main.bin 0x8000000
+ st-flash write _$(PREFIX)_obs/main.bin 0x8000000
clean:
- rm -f *.o *.elf *.bin
+ rm -rf _*_obs
genmake:
./genmake.pl > Makefile