diff options
author | a_p_u_r_o <applause@elfmimi.jp> | 2019-11-24 01:01:03 +0900 |
---|---|---|
committer | Florian Didron <fdidron@users.noreply.github.com> | 2020-01-06 12:21:46 +0900 |
commit | bf09fa6148f4e531d3c201d5a761b84cabf4f197 (patch) | |
tree | 2eaa4a653a2220a6585eedb6657fb71dd3c5f605 /tmk_core/rules.mk | |
parent | 2fe7d6aea2e2ae2da7d0a41266a2084f8c8ca919 (diff) |
Remove CR when computing BOOTLOADER_SIZE. (#7453)
Diffstat (limited to 'tmk_core/rules.mk')
-rw-r--r-- | tmk_core/rules.mk | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tmk_core/rules.mk b/tmk_core/rules.mk index 31bce33c39..334ff314be 100644 --- a/tmk_core/rules.mk +++ b/tmk_core/rules.mk @@ -397,7 +397,7 @@ ifeq ($(findstring avr-gcc,$(CC)),avr-gcc) SIZE_MARGIN = 1024 check-size: - $(eval MAX_SIZE=$(shell n=`$(CC) -E -mmcu=$(MCU) $(CFLAGS) $(OPT_DEFS) tmk_core/common/avr/bootloader_size.c 2> /dev/null | sed -ne '/^#/n;/^AVR_SIZE:/,$${s/^AVR_SIZE: //;p;}'` && echo $$(($$n)) || echo 0)) + $(eval MAX_SIZE=$(shell n=`$(CC) -E -mmcu=$(MCU) $(CFLAGS) $(OPT_DEFS) tmk_core/common/avr/bootloader_size.c 2> /dev/null | sed -ne 's/\r//;/^#/n;/^AVR_SIZE:/,$${s/^AVR_SIZE: //;p;}'` && echo $$(($$n)) || echo 0)) $(eval CURRENT_SIZE=$(shell if [ -f $(BUILD_DIR)/$(TARGET).hex ]; then $(SIZE) --target=$(FORMAT) $(BUILD_DIR)/$(TARGET).hex | $(AWK) 'NR==2 {print $$4}'; else printf 0; fi)) $(eval FREE_SIZE=$(shell expr $(MAX_SIZE) - $(CURRENT_SIZE))) $(eval OVER_SIZE=$(shell expr $(CURRENT_SIZE) - $(MAX_SIZE))) |