Bastian Blank
2008-Mar-21 13:01 UTC
[Xen-devel] [PATCH 3/8] tools/vtpm_manager - Cleanup makefiles
# HG changeset patch # User Bastian Blank <waldi@debian.org> # Date 1206103830 -3600 # Node ID fcbda0690b0f41f6b5abc93961e22797dec48789 # Parent e6eb37e6d2f7e0f17ebe674d30253d3e832b1bce Cleanup makefiles. Remove unnecessary openssl check. Use VPATH. Make clean remove all generated files. Signed-off-by: Bastian Blank <waldi@debian.org> diff -r e6eb37e6d2f7 -r fcbda0690b0f tools/vtpm_manager/Makefile --- a/tools/vtpm_manager/Makefile Fri Mar 21 13:50:30 2008 +0100 +++ b/tools/vtpm_manager/Makefile Fri Mar 21 13:50:30 2008 +0100 @@ -7,23 +7,13 @@ OPENSSL_HEADER = /usr/include/openssl/cr OPENSSL_HEADER = /usr/include/openssl/crypto.h .PHONY: all -all: build - -.PHONY: build -build: - @set -e; if [ -e $(OPENSSL_HEADER) ]; then \ - if [ ! -e "migration/vtpm_ipc.c" ]; then \ - ln -s ../manager/vtpm_ipc.c migration; \ - fi; \ - for subdir in $(SUBDIRS); do \ - $(MAKE) -C $$subdir $@; \ - done; \ - else \ - echo "*** Cannot build vtpm_manager: OpenSSL developement files missing."; \ - fi +all: + for subdir in $(SUBDIRS); do \ + $(MAKE) -C $$subdir $@; \ + done .PHONY: install -install: build +install: @set -e; for subdir in $(SUBDIRS); do \ $(MAKE) -C $$subdir $@; \ done @@ -37,7 +27,6 @@ clean: .PHONY: mrproper mrproper: - rm -f migration/vtpm_ipc.c @set -e; for subdir in $(SUBDIRS); do \ $(MAKE) -C $$subdir $@; \ done diff -r e6eb37e6d2f7 -r fcbda0690b0f tools/vtpm_manager/manager/Makefile --- a/tools/vtpm_manager/manager/Makefile Fri Mar 21 13:50:30 2008 +0100 +++ b/tools/vtpm_manager/manager/Makefile Fri Mar 21 13:50:30 2008 +0100 @@ -21,11 +21,12 @@ install: build .PHONY: clean clean: + rm -f $(BIN) rm -f *.a *.so *.o *.rpm $(DEP_FILES) .PHONY: mrproper mrproper: clean - rm -f $(BIN) *~ + rm -f *~ $(BIN): $(OBJS) $(CC) $(CFLAGS) $(LDFLAGS) $^ $(LIBS) -o $@ diff -r e6eb37e6d2f7 -r fcbda0690b0f tools/vtpm_manager/migration/Makefile --- a/tools/vtpm_manager/migration/Makefile Fri Mar 21 13:50:30 2008 +0100 +++ b/tools/vtpm_manager/migration/Makefile Fri Mar 21 13:50:30 2008 +0100 @@ -1,5 +1,7 @@ XEN_ROOT = ../../.. XEN_ROOT = ../../.. include $(XEN_ROOT)/tools/vtpm_manager/Rules.mk + +VPATH = ../manager BIND = vtpm_migratord BINC = vtpm_migrator @@ -23,11 +25,12 @@ install: build .PHONY: clean clean: + rm -f $(BINC) $(BIND) rm -f *.a *.so *.o *.rpm $(DEP_FILES) .PHONY: mrproper mrproper: clean - rm -f $(BINC) $(BIND) *~ + rm -f *~ $(BIND): $(OBJSD) $(CC) $(CFLAGS) $(LDFLAGS) $^ $(LIBS) -o $@ -- I''m frequently appalled by the low regard you Earthmen have for life. -- Spock, "The Galileo Seven", stardate 2822.3 _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel