From 470887eddd4d4835057d482a7e9daa54619ab03b Mon Sep 17 00:00:00 2001 From: David Kopf Date: Wed, 31 Aug 2011 11:50:14 -0400 Subject: [PATCH] Print elf size if ELF_SIZE is defined --- cpu/avr/Makefile.avr | 1 + examples/webserver-ipv6/Makefile | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/cpu/avr/Makefile.avr b/cpu/avr/Makefile.avr index a98c8e44d..8a94b9eb0 100644 --- a/cpu/avr/Makefile.avr +++ b/cpu/avr/Makefile.avr @@ -105,6 +105,7 @@ CC = avr-gcc LD = avr-gcc AS = avr-as AR = avr-ar +ELF_SIZE = avr-size -C --mcu=$(MCU) OBJCOPY = avr-objcopy STRIP = avr-strip CFLAGSNO = -Wall -mmcu=$(MCU) -gdwarf-2 -fno-strict-aliasing \ diff --git a/examples/webserver-ipv6/Makefile b/examples/webserver-ipv6/Makefile index 549656638..c87a5e85b 100644 --- a/examples/webserver-ipv6/Makefile +++ b/examples/webserver-ipv6/Makefile @@ -25,8 +25,12 @@ endif #copy output to e.g. webserver-nano.sky, raven-webserver.avr-raven $(WITH_WEBSERVER) : $(CONTIKI_PROJECT) cp $(CONTIKI_PROJECT).$(TARGET) $(WITH_WEBSERVER).$(TARGET) + @if (test -n "$(ELF_SIZE)");then $(ELF_SIZE) $(WITH_WEBSERVER).$(TARGET);fi else APPS=webserver + +all : $(CONTIKI_PROJECT) + @if (test -n "$(ELF_SIZE)");then $(ELF_SIZE) $(CONTIKI_PROJECT).$(TARGET);fi endif UIP_CONF_IPV6=1