Browse Source

[makefile] Allow .sizes target to work with funny-named objects

The bin/xxx.sizes targets examine the list of obj_ symbols in bin/xxx.tmp
to determine which objects to measure the size of. These symbols have been
normalized to C identifiers, so the result is an error message from `size'
when examining a target that includes objects that were originally named
with hyphens.

Fix by turning obj_foo_bar into $(wildcard bin/foo?bar.o) instead of
bin/foo_bar.o.

Signed-off-by: Marty Connor <mdc@etherboot.org>
tags/v1.0.0-rc1
Joshua Oreman 15 years ago
parent
commit
f94845168a
1 changed files with 1 additions and 1 deletions
  1. 1
    1
      src/Makefile.housekeeping

+ 1
- 1
src/Makefile.housekeeping View File

@@ -677,7 +677,7 @@ endef
677 677
 $(BIN)/%.objs : $(BIN)/%.tmp
678 678
 	$(Q)$(ECHO) $(call objs_list,$<)
679 679
 $(BIN)/%.sizes : $(BIN)/%.tmp
680
-	$(Q)$(SIZE) -t $(foreach OBJ,$(call objs_list,$<),$(BIN)/$(OBJ).o) | \
680
+	$(Q)$(SIZE) -t $(foreach OBJ,$(call objs_list,$<),$(wildcard $(BIN)/$(subst _,?,$(OBJ)).o)) | \
681 681
 		sort -g
682 682
 
683 683
 # Get dependency list for the specified target

Loading…
Cancel
Save