Speed up build tests by only building each test to the ELF output stage (when all files are compiled and linked), rather than to the full HEX output stage as the resulting binary is not actually required.

pull/1469/head
Dean Camera 13 years ago
parent e5a7fa201e
commit 7a7ee6a908

@ -1,4 +1,6 @@
# BOARD DEFINE = {ARCH} : {MCU} : # BOARD DEFINE = {ARCH} : {MCU} :
BOARD_USER = avr8 : at90usb1287 :
BOARD_NONE = avr8 : at90usb1287 :
BOARD_USBKEY = avr8 : at90usb1287 : BOARD_USBKEY = avr8 : at90usb1287 :
BOARD_STK525 = avr8 : at90usb647 : BOARD_STK525 = avr8 : at90usb647 :
BOARD_STK526 = avr8 : at90usb162 : BOARD_STK526 = avr8 : at90usb162 :

@ -30,6 +30,7 @@ makeboardlist:
testboards: testboards:
echo "buildtest:" > BuildMakefile echo "buildtest:" > BuildMakefile
@while read line; \ @while read line; \
do \ do \
build_cfg=`grep "$$line " BoardDeviceMap.cfg | sed 's/ //g' | cut -d'=' -f2-`; \ build_cfg=`grep "$$line " BoardDeviceMap.cfg | sed 's/ //g' | cut -d'=' -f2-`; \
@ -45,9 +46,10 @@ testboards:
\ \
printf "\t@echo Building dummy project for $$build_board...\n" >> BuildMakefile; \ printf "\t@echo Building dummy project for $$build_board...\n" >> BuildMakefile; \
printf "\tmake -s -f makefile.%s clean\n" $$build_arch >> BuildMakefile; \ printf "\tmake -s -f makefile.%s clean\n" $$build_arch >> BuildMakefile; \
printf "\tmake -s -f makefile.%s MCU=%s BOARD=%s\n\n" $$build_arch $$build_mcu $$build_board >> BuildMakefile; \ printf "\tmake -s -f makefile.%s MCU=%s BOARD=%s elf\n\n" $$build_arch $$build_mcu $$build_board >> BuildMakefile; \
fi; \ fi; \
done < BoardList.txt done < BoardList.txt
$(MAKE) -f BuildMakefile buildtest $(MAKE) -f BuildMakefile buildtest
clean: clean:

@ -37,21 +37,21 @@ end:
@echo @echo
%.avr8: %.avr8:
$(MAKE) -f makefile.avr8 clean -s $(MAKE) -s -f makefile.avr8 clean
$(MAKE) -f makefile.avr8 all MCU=$(@:%.avr8=%) -s $(MAKE) -s -f makefile.avr8 all MCU=$(@:%.avr8=%) elf
%.xmega: %.xmega:
$(MAKE) -f makefile.xmega clean -s $(MAKE) -s -f makefile.xmega clean
$(MAKE) -f makefile.xmega all MCU=$(@:%.xmega=%) -s $(MAKE) -s -f makefile.xmega all MCU=$(@:%.xmega=%) elf
%.uc3: %.uc3:
$(MAKE) -f makefile.uc3 clean -s $(MAKE) -s -f makefile.uc3 clean
$(MAKE) -f makefile.uc3 all MCU=$(@:%.uc3=%) -s $(MAKE) -s -f makefile.uc3 all MCU=$(@:%.uc3=%) elf
clean: clean:
$(MAKE) -f makefile.avr8 clean -s $(MAKE) -s -f makefile.avr8 clean
$(MAKE) -f makefile.xmega clean -s $(MAKE) -s -f makefile.xmega clean
$(MAKE) -f makefile.uc3 clean -s $(MAKE) -s -f makefile.uc3 clean
%: %:

@ -23,23 +23,23 @@ end:
@echo @echo
compile: compile:
$(MAKE) -f makefile.avr8 clean -s $(MAKE) -s -f makefile.avr8 clean
$(MAKE) -f makefile.avr8 LUFA_OPTS='-D USB_DEVICE_ONLY' -s $(MAKE) -s -f makefile.avr8 LUFA_OPTS='-D USB_DEVICE_ONLY' elf
$(MAKE) -f makefile.avr8 clean -s $(MAKE) -s -f makefile.avr8 clean
$(MAKE) -f makefile.avr8 LUFA_OPTS='-D USB_HOST_ONLY' -s $(MAKE) -s -f makefile.avr8 LUFA_OPTS='-D USB_HOST_ONLY' elf
$(MAKE) -f makefile.xmega clean -s $(MAKE) -s -f makefile.xmega clean
$(MAKE) -f makefile.xmega LUFA_OPTS='-D USB_DEVICE_ONLY' -s $(MAKE) -s -f makefile.xmega LUFA_OPTS='-D USB_DEVICE_ONLY' elf
$(MAKE) -f makefile.uc3 clean -s $(MAKE) -s -f makefile.uc3 clean
$(MAKE) -f makefile.uc3 LUFA_OPTS='-D USB_DEVICE_ONLY' -s $(MAKE) -s -f makefile.uc3 LUFA_OPTS='-D USB_DEVICE_ONLY' elf
$(MAKE) -f makefile.uc3 clean -s $(MAKE) -s -f makefile.uc3 clean
$(MAKE) -f makefile.uc3 LUFA_OPTS='-D USB_HOST_ONLY' -s $(MAKE) -s -f makefile.uc3 LUFA_OPTS='-D USB_HOST_ONLY' elf
clean: clean:
$(MAKE) -f makefile.avr8 clean -s $(MAKE) -s -f makefile.avr8 clean
$(MAKE) -f makefile.xmega clean -s $(MAKE) -s -f makefile.xmega clean
$(MAKE) -f makefile.uc3 clean -s $(MAKE) -s -f makefile.uc3 clean
%: %:

@ -11,13 +11,8 @@
# not intended to be modified or compiled by non-developers. # not intended to be modified or compiled by non-developers.
all: all:
$(MAKE) -C ModuleTest all
$(MAKE) -C SingleUSBModeTest all
$(MAKE) -C StaticAnalysisTest all
$(MAKE) -C BoardDriverTest all
%: %:
$(MAKE) -C BoardDriverTest $@
$(MAKE) -C ModuleTest $@ $(MAKE) -C ModuleTest $@
$(MAKE) -C SingleUSBModeTest $@ $(MAKE) -C SingleUSBModeTest $@
$(MAKE) -C StaticAnalysisTest $@ $(MAKE) -C StaticAnalysisTest $@
$(MAKE) -C BoardDriverTest $@

Loading…
Cancel
Save