[BUILD] Make the binaries only needed for the user

User can specify which binaries he needs on the commandline.

'make hex' will build examples with generating hex file
'make hex bin' will build hex and bin output
'make images' will build all images as in previous versions of buildsystem
'make all' or 'make' will build only elf (+ map) files

This will have huge impact on build speed.
This commit is contained in:
Frantisek Burian
2014-02-13 19:35:18 +01:00
parent 3f47411e24
commit 3af1f8d43d
2 changed files with 24 additions and 4 deletions

View File

@@ -123,7 +123,13 @@ LDLIBS += -Wl,--start-group -lc -lgcc -lnosys -Wl,--end-group
.SECONDEXPANSION:
.SECONDARY:
all: images
all: elf
elf: $(BINARY).elf
bin: $(BINARY).bin
hex: $(BINARY).hex
srec: $(BINARY).srec
list: $(BINARY).list
images: $(BINARY).images
flash: $(BINARY).flash
@@ -228,6 +234,6 @@ else
$(*).elf
endif
.PHONY: images clean stylecheck styleclean
.PHONY: images clean stylecheck styleclean elf bin hex srec list
-include $(OBJS:.o=.d)