ia64/xen-unstable

changeset 13659:4dd3266e13a7

[TCGBIOS] Fix some makefile issues.
Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
author kaf24@localhost.localdomain
date Fri Jan 26 16:46:00 2007 +0000 (2007-01-26)
parents edbff1762a55
children aae5932afc6d
files tools/firmware/rombios/32bit/Makefile tools/firmware/rombios/32bit/tcgbios/Makefile
line diff
     1.1 --- a/tools/firmware/rombios/32bit/Makefile	Fri Jan 26 16:39:38 2007 +0000
     1.2 +++ b/tools/firmware/rombios/32bit/Makefile	Fri Jan 26 16:46:00 2007 +0000
     1.3 @@ -12,33 +12,29 @@ CFLAGS += -I../
     1.4  
     1.5  SUBDIRS = tcgbios
     1.6  
     1.7 -MODULES := 32bitbios.o
     1.8 -MODULES += tcgbios/tcgbiosext.o
     1.9 -MODULES += util.o
    1.10 +MODULES = tcgbios/tcgbiosext.o
    1.11  
    1.12 -.PHONY: all subdirs
    1.13 +.PHONY: all subdirs clean
    1.14  
    1.15  subdirs:
    1.16  	@for subdir in $(SUBDIRS); do \
    1.17  		$(MAKE) -C $$subdir all; \
    1.18  	done;
    1.19  
    1.20 -all: subdirs $(TARGET)
    1.21 +all: $(TARGET)
    1.22  
    1.23 -clean::
    1.24 +clean:
    1.25  	rm -rf *.o $(TARGET)
    1.26  	@for subdir in $(SUBDIRS); do \
    1.27  		$(MAKE) -C $$subdir $@; \
    1.28  	done;
    1.29  
    1.30 -$(TARGET): 32bitbios_all.o $(SOURCES)
    1.31 -	unref=`nm -u 32bitbios_all.o`
    1.32 -	@if [ "$$unref" != "" ]; then \
    1.33 -		echo "There are unresolved symbols in the BIOS.";	\
    1.34 -		echo $$unref ;						\
    1.35 -	else								\
    1.36 -		bash mkhex highbios_array 32bitbios_all.o > $(TARGET); \
    1.37 -	fi
    1.38 -
    1.39 -32bitbios_all.o: $(MODULES)
    1.40 -	ld $(LDFLAGS_DIRECT) -r $(MODULES) -o 32bitbios_all.o
    1.41 +$(TARGET): subdirs 32bitbios.o util.o
    1.42 +	ld $(LDFLAGS_DIRECT) -r 32bitbios.o $(MODULES) util.o -o 32bitbios_all.o
    1.43 +	@nm 32bitbios_all.o |                                \
    1.44 +	  grep -E -q '^ +U ' && {                            \
    1.45 +	    echo "There are undefined symbols in the BIOS:"; \
    1.46 +	    nm -u 32bitbios_all.o;                           \
    1.47 +	    exit 11;                                         \
    1.48 +	  } || :
    1.49 +	bash mkhex highbios_array 32bitbios_all.o > $@
     2.1 --- a/tools/firmware/rombios/32bit/tcgbios/Makefile	Fri Jan 26 16:39:38 2007 +0000
     2.2 +++ b/tools/firmware/rombios/32bit/tcgbios/Makefile	Fri Jan 26 16:46:00 2007 +0000
     2.3 @@ -11,9 +11,11 @@ OBJECTS = $(foreach f,$(FILES),$(f).o)
     2.4  CFLAGS += -fno-builtin -O2 -msoft-float -nostdlib
     2.5  CFLAGS += -I../ -I../../
     2.6  
     2.7 +.PHONY: all clean
     2.8 +
     2.9  all: $(TARGET)
    2.10  
    2.11 -clean::
    2.12 +clean:
    2.13  	rm -rf *.o $(TARGET)
    2.14  
    2.15  $(TARGET): $(OBJECTS)