diff --git a/build.mk b/build.mk index 5aba085..4c9c71b 100644 --- a/build.mk +++ b/build.mk @@ -140,20 +140,30 @@ else $(CC) -o $(BINDIR)/$(TARGET_VER).elf $(ALLOBJS) $(LIBS) $(LDFLAGS) endif +ifndef NO_SYM $(NM) -t d -S --size-sort $(BINDIR)/$(TARGET_VER).elf > $(BINDIR)/$(TARGET_VER).sym +endif +ifndef NO_LST $(OBJDUMP) -xds -S -l $(BINDIR)/$(TARGET_VER).elf > $(BINDIR)/$(TARGET_VER).lst +endif ifeq ($(RELEASE), yes) $(STRIP) --strip-debug --strip-unneeded $(BINDIR)/$(TARGET_VER).elf endif +ifndef NO_SIZE @$(SIZE) -A -d $(BINDIR)/$(TARGET_VER).elf +endif $(EMPTY_LINE) $(BINDIR)/$(TARGET_VER).a: $(MAKEFILE_LIST) $(ALLOBJS) | $(BINDIR)/ @$(ECHO) "Creating static library ..." $(AR) rcs $(BINDIR)/$(TARGET_VER).a $(ALLOBJS) +ifndef NO_SYM $(NM) -t d -S --size-sort $(BINDIR)/$(TARGET_VER).a > $(BINDIR)/$(TARGET_VER)_a.sym +endif +ifndef NO_LST $(OBJDUMP) -xds -S -l $(BINDIR)/$(TARGET_VER).a > $(BINDIR)/$(TARGET_VER)_a.lst +endif ifeq ($(RELEASE), yes) $(STRIP) --strip-debug --strip-unneeded $(BINDIR)/$(TARGET_VER).a endif @@ -167,8 +177,12 @@ else $(CC) -o $(BINDIR)/$(TARGET_VER).so $(ALLOBJS) $(LIBS) $(LDFLAGS) -rdynamic -shared -Wl,-soname,$(TARGET).so endif +ifndef NO_SYM $(NM) -t d -S --size-sort $(BINDIR)/$(TARGET_VER).so > $(BINDIR)/$(TARGET_VER)_so.sym +endif +ifndef NO_LST $(OBJDUMP) -xds -S -l $(BINDIR)/$(TARGET_VER).so > $(BINDIR)/$(TARGET_VER)_so.lst +endif ifeq ($(RELEASE), yes) $(STRIP) --strip-debug --strip-unneeded $(BINDIR)/$(TARGET_VER).so endif