X-Git-Url: http://git.linex4red.de/pub/USBaspLoader.git/blobdiff_plain/75fda0918116faee3b7f9b83bf0c60801175abbf..fa1b0642d26d0b5ed3ce0331bac026c2b2c18124:/updater/Makefile diff --git a/updater/Makefile b/updater/Makefile index a3aa145..7764cad 100644 --- a/updater/Makefile +++ b/updater/Makefile @@ -36,15 +36,22 @@ endif all: updater.hex +flash: all + $(ECHO) "." + $(AVRDUDE) -D -U flash:w:updater.hex:i + $(ECHO) "." + $(ECHO) "." + + ../firmware/main.bin: $(MAKE) -C ../firmware main.hex -usbasploader.raw: +usbasploader.raw: ../firmware/main.bin $(OBC) -j .text -j .data -O binary ../firmware/main.bin usbasploader.raw usbasploader.o: usbasploader.raw - $(OBC) -I binary -O elf32-avr --rename-section .data=.text --redefine-sym _binary_usbasploader_raw_start=usbasploader usbasploader.raw usbasploader.o + $(OBC) -B $(MCUARCH) -I binary -O elf32-avr --rename-section .data=.text --redefine-sym _binary_usbasploader_raw_start=usbasploader usbasploader.raw usbasploader.o updater.o: updater.c usbasploader.h usbasploader.raw usbasploader.o @@ -57,18 +64,17 @@ updater.elf: updater.o usbasploader.o updater.hex: updater.elf $(OBC) -j .text -j .data -O ihex updater.elf updater.hex $(ECHO) "." - $(SIZ) updater.elf $(ECHO) "." - $(AVRDUDE) -D -U flash:w:updater.hex:i + $(SIZ) updater.elf $(ECHO) "." - deepclean: clean $(RM) *~ clean: - $(RM) *.o - $(RM) *.raw + $(RM) usbasploader.o + $(RM) updater.o + $(RM) usbasploader.raw $(RM) updater.hex $(RM) updater.elf $(RM) usbasploader.raw \ No newline at end of file