ia64/xen-unstable

changeset 19026:bd78714b8594

Use -MMD -MF in tools/* rather than -Wp,-M...

If you use -MMD -MF then the correct .o filename is written to the
.*.d file as the compiler driver arranges everything. This was done
in 19010:275abe1c5d24 for the hypervisor.

In this patch we do the same elsewhere in the xen-unstable tree,
particularly tools/. Specifically:
* Change tools/Rules.mk to add -MMD -MF ... to CFLAGS and set DEPS.
* Remove -Wp,-MD... from every other Makefile
* Remove setting of DEPS from every other Makefile
* Ensure that every Makefile says -include $(DEPS)
* Ensure that every Makefile's clean target removes $(DEPS)

Some Makefiles were already halfway there, but often for a different
variable name eg PROG_DEP. The variable name is now standardised in
Rules.mk as DEPS.

I have done a test build with this change, on Debian etch.

Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
author Keir Fraser <keir.fraser@citrix.com>
date Mon Jan 12 10:16:05 2009 +0000 (2009-01-12)
parents b999142bca8c
children 59d511c4a8d8
files tools/Rules.mk tools/blktap/drivers/Makefile tools/console/Makefile tools/firmware/hvmloader/Makefile tools/firmware/hvmloader/acpi/Makefile tools/firmware/rombios/32bit/Makefile tools/firmware/rombios/32bit/tcgbios/Makefile tools/firmware/rombios/Makefile tools/flask/libflask/Makefile tools/flask/loadpolicy/Makefile tools/fs-back/Makefile tools/libfsimage/Rules.mk tools/libfsimage/common/Makefile tools/libxc/Makefile tools/misc/Makefile tools/pygrub/Makefile tools/python/Makefile tools/vnet/libxutil/Makefile tools/vtpm/Rules.mk tools/vtpm_manager/Rules.mk tools/xcutils/Makefile tools/xenmon/Makefile tools/xenpmd/Makefile tools/xenstat/libxenstat/Makefile tools/xenstat/xentop/Makefile tools/xenstore/Makefile tools/xentrace/Makefile xen/arch/ia64/tools/p2m_foreign/Makefile
line diff
     1.1 --- a/tools/Rules.mk	Fri Jan 09 16:56:54 2009 +0000
     1.2 +++ b/tools/Rules.mk	Mon Jan 12 10:16:05 2009 +0000
     1.3 @@ -29,6 +29,10 @@ X11_LDPATH = -L/usr/X11R6/$(LIBLEAFDIR)
     1.4  
     1.5  CFLAGS += -D__XEN_TOOLS__
     1.6  
     1.7 +# Get gcc to generate the dependencies for us.
     1.8 +CFLAGS += -MMD -MF .$(@F).d
     1.9 +DEPS = .*.d
    1.10 +
    1.11  # Enable implicit LFS support *and* explicit LFS names.
    1.12  CFLAGS  += $(shell getconf LFS_CFLAGS)
    1.13  CFLAGS  += -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE
    1.14 @@ -59,4 +63,3 @@ subdirs-all subdirs-clean subdirs-instal
    1.15  
    1.16  subdir-all-% subdir-clean-% subdir-install-%: .phony
    1.17  	$(MAKE) -C $* $(patsubst subdir-%-$*,%,$@)
    1.18 -
     2.1 --- a/tools/blktap/drivers/Makefile	Fri Jan 09 16:56:54 2009 +0000
     2.2 +++ b/tools/blktap/drivers/Makefile	Mon Jan 12 10:16:05 2009 +0000
     2.3 @@ -13,10 +13,6 @@ CFLAGS   += $(CFLAGS_libxenstore)
     2.4  CFLAGS   += -I $(LIBAIO_DIR)
     2.5  CFLAGS   += -D_GNU_SOURCE
     2.6  
     2.7 -# Get gcc to generate the dependencies for us.
     2.8 -CFLAGS   += -Wp,-MD,.$(@F).d
     2.9 -DEPS      = .*.d
    2.10 -
    2.11  ifeq ($(shell . ./check_gcrypt),"yes")
    2.12  CFLAGS += -DUSE_GCRYPT
    2.13  CRYPT_LIB := -lgcrypt
     3.1 --- a/tools/console/Makefile	Fri Jan 09 16:56:54 2009 +0000
     3.2 +++ b/tools/console/Makefile	Mon Jan 12 10:16:05 2009 +0000
     3.3 @@ -16,7 +16,7 @@ all: $(BIN)
     3.4  
     3.5  .PHONY: clean
     3.6  clean:
     3.7 -	$(RM) *.a *.so *.o *.rpm $(BIN)
     3.8 +	$(RM) *.a *.so *.o *.rpm $(BIN) $(DEPS)
     3.9  	$(RM) client/*.o daemon/*.o
    3.10  
    3.11  xenconsoled: $(patsubst %.c,%.o,$(wildcard daemon/*.c))
    3.12 @@ -33,3 +33,5 @@ install: $(BIN)
    3.13  	$(INSTALL_PROG) xenconsoled $(DESTDIR)/$(SBINDIR)
    3.14  	$(INSTALL_DIR) $(DESTDIR)$(PRIVATE_BINDIR)
    3.15  	$(INSTALL_PROG) xenconsole $(DESTDIR)$(PRIVATE_BINDIR)
    3.16 +
    3.17 +-include $(DEPS)
     4.1 --- a/tools/firmware/hvmloader/Makefile	Fri Jan 09 16:56:54 2009 +0000
     4.2 +++ b/tools/firmware/hvmloader/Makefile	Mon Jan 12 10:16:05 2009 +0000
     4.3 @@ -58,4 +58,6 @@ roms.h: ../rombios/BIOS-bochs-latest ../
     4.4  .PHONY: clean
     4.5  clean: subdirs-clean
     4.6  	rm -f roms.h acpi.h
     4.7 -	rm -f hvmloader hvmloader.tmp *.o
     4.8 +	rm -f hvmloader hvmloader.tmp *.o $(DEPS)
     4.9 +
    4.10 +-include $(DEPS)
     5.1 --- a/tools/firmware/hvmloader/acpi/Makefile	Fri Jan 09 16:56:54 2009 +0000
     5.2 +++ b/tools/firmware/hvmloader/acpi/Makefile	Mon Jan 12 10:16:05 2009 +0000
     5.3 @@ -63,6 +63,8 @@ acpi.a: $(OBJS)
     5.4  	$(CC) $(CPPFLAGS) $(CFLAGS) -c -o $@ $<
     5.5  
     5.6  clean:
     5.7 -	rm -rf *.a *.o $(IASL_VER) $(IASL_VER).tar.gz
     5.8 +	rm -rf *.a *.o $(IASL_VER) $(IASL_VER).tar.gz $(DEPS)
     5.9  
    5.10  install: all
    5.11 +
    5.12 +-include $(DEPS)
     6.1 --- a/tools/firmware/rombios/32bit/Makefile	Fri Jan 09 16:56:54 2009 +0000
     6.2 +++ b/tools/firmware/rombios/32bit/Makefile	Mon Jan 12 10:16:05 2009 +0000
     6.3 @@ -16,7 +16,7 @@ all: subdirs-all
     6.4  
     6.5  .PHONY: clean
     6.6  clean: subdirs-clean
     6.7 -	rm -rf *.o $(TARGET)
     6.8 +	rm -rf *.o $(TARGET) $(DEPS)
     6.9  
    6.10  $(TARGET): 32bitbios.o $(MODULES) util.o
    6.11  	$(LD) $(LDFLAGS_DIRECT) -s -r $^ -o 32bitbios_all.o
    6.12 @@ -27,3 +27,5 @@ clean: subdirs-clean
    6.13  	    exit 11;                                         \
    6.14  	  } || :
    6.15  	sh mkhex highbios_array 32bitbios_all.o > $@
    6.16 +
    6.17 +-include $(DEPS)
     7.1 --- a/tools/firmware/rombios/32bit/tcgbios/Makefile	Fri Jan 09 16:56:54 2009 +0000
     7.2 +++ b/tools/firmware/rombios/32bit/tcgbios/Makefile	Mon Jan 12 10:16:05 2009 +0000
     7.3 @@ -12,7 +12,10 @@ CFLAGS += $(CFLAGS_include) -I.. -I../..
     7.4  all: $(TARGET)
     7.5  
     7.6  clean:
     7.7 -	rm -rf *.o $(TARGET)
     7.8 +	rm -rf *.o $(TARGET) $(DEPS)
     7.9  
    7.10  $(TARGET): $(OBJECTS)
    7.11  	$(LD) $(LDFLAGS_DIRECT) -r $^ -o $@
    7.12 +
    7.13 +-include $(DEPS)
    7.14 +
     8.1 --- a/tools/firmware/rombios/Makefile	Fri Jan 09 16:56:54 2009 +0000
     8.2 +++ b/tools/firmware/rombios/Makefile	Mon Jan 12 10:16:05 2009 +0000
     8.3 @@ -13,6 +13,7 @@ clean: subdirs-clean
     8.4  	rm -f  as86-sym.txt ld86-sym.txt 
     8.5  	rm -f  rombios*.txt rombios*.sym usage biossums
     8.6  	rm -f  BIOS-bochs-*
     8.7 +	rm -f  $(DEPS)
     8.8  
     8.9  BIOS-bochs-latest: rombios.c biossums 32bitgateway.c tcgbios.c
    8.10  	gcc -DBX_SMP_PROCESSORS=1 -E -P $< > _rombios_.c
    8.11 @@ -27,3 +28,4 @@ BIOS-bochs-latest: rombios.c biossums 32
    8.12  biossums: biossums.c
    8.13  	gcc -o biossums biossums.c
    8.14  
    8.15 +-include $(DEPS)
     9.1 --- a/tools/flask/libflask/Makefile	Fri Jan 09 16:56:54 2009 +0000
     9.2 +++ b/tools/flask/libflask/Makefile	Mon Jan 12 10:16:05 2009 +0000
     9.3 @@ -16,7 +16,6 @@ CFLAGS   += $(INCLUDES) -I./include -I$(
     9.4  # Get gcc to generate the dependencies for us.
     9.5  CFLAGS   += -Wp,-MD,.$(@F).d
     9.6  LDFLAGS  += -L.
     9.7 -DEPS     = .*.d
     9.8  
     9.9  LIB_OBJS := $(patsubst %.c,%.o,$(SRCS))
    9.10  PIC_OBJS := $(patsubst %.c,%.opic,$(SRCS))
    10.1 --- a/tools/flask/loadpolicy/Makefile	Fri Jan 09 16:56:54 2009 +0000
    10.2 +++ b/tools/flask/loadpolicy/Makefile	Mon Jan 12 10:16:05 2009 +0000
    10.3 @@ -7,9 +7,6 @@ LIBFLASK_ROOT = $(XEN_ROOT)/tools/flask/
    10.4  
    10.5  PROFILE=#-pg
    10.6  BASECFLAGS=-Wall -g -Werror
    10.7 -# Make gcc generate dependencies.
    10.8 -BASECFLAGS += -Wp,-MD,.$(@F).d
    10.9 -PROG_DEP = .*.d
   10.10  BASECFLAGS+= $(PROFILE)
   10.11  #BASECFLAGS+= -I$(XEN_ROOT)/tools
   10.12  BASECFLAGS+= $(CFLAGS_libxenctrl)
   10.13 @@ -39,7 +36,7 @@ all: $(CLIENTS)
   10.14  clean: 
   10.15  	rm -f *.o *.opic *.so
   10.16  	rm -f $(CLIENTS)
   10.17 -	$(RM) $(PROG_DEP)
   10.18 +	$(RM) $(DEPS)
   10.19  
   10.20  .PHONY: print-dir
   10.21  print-dir:
   10.22 @@ -54,7 +51,7 @@ install: all
   10.23  	$(INSTALL_DIR) $(DESTDIR)$(SBINDIR)
   10.24  	$(INSTALL_PROG) $(CLIENTS) $(DESTDIR)$(SBINDIR)
   10.25  
   10.26 --include $(PROG_DEP)
   10.27 +-include $(DEPS)
   10.28  
   10.29  # never delete any intermediate files.
   10.30  .SECONDARY:
    11.1 --- a/tools/fs-back/Makefile	Fri Jan 09 16:56:54 2009 +0000
    11.2 +++ b/tools/fs-back/Makefile	Mon Jan 12 10:16:05 2009 +0000
    11.3 @@ -13,10 +13,6 @@ CFLAGS   += $(CFLAGS_libxenstore)
    11.4  CFLAGS   += $(INCLUDES) -I.
    11.5  CFLAGS   += -D_GNU_SOURCE
    11.6  
    11.7 -# Get gcc to generate the dependencies for us.
    11.8 -CFLAGS   += -Wp,-MD,.$(@F).d
    11.9 -DEPS      = .*.d
   11.10 -
   11.11  LIBS      := -L. -L.. -L../lib
   11.12  LIBS      += $(LDFLAGS_libxenctrl)
   11.13  LIBS      += $(LDFLAGS_libxenstore)
    12.1 --- a/tools/libfsimage/Rules.mk	Fri Jan 09 16:56:54 2009 +0000
    12.2 +++ b/tools/libfsimage/Rules.mk	Mon Jan 12 10:16:05 2009 +0000
    12.3 @@ -1,8 +1,6 @@
    12.4  include $(XEN_ROOT)/tools/Rules.mk
    12.5  
    12.6 -DEPS = .*.d
    12.7 -
    12.8 -CFLAGS += -I$(XEN_ROOT)/tools/libfsimage/common/ -Werror -Wp,-MD,.$(@F).d
    12.9 +CFLAGS += -I$(XEN_ROOT)/tools/libfsimage/common/ -Werror
   12.10  LDFLAGS += -L../common/
   12.11  
   12.12  PIC_OBJS := $(patsubst %.c,%.opic,$(LIB_SRCS-y))
    13.1 --- a/tools/libfsimage/common/Makefile	Fri Jan 09 16:56:54 2009 +0000
    13.2 +++ b/tools/libfsimage/common/Makefile	Mon Jan 12 10:16:05 2009 +0000
    13.3 @@ -4,9 +4,6 @@ include $(XEN_ROOT)/tools/Rules.mk
    13.4  MAJOR = 1.0
    13.5  MINOR = 0
    13.6  
    13.7 -CFLAGS += -Werror -Wp,-MD,.$(@F).d
    13.8 -DEPS = .*.d
    13.9 -
   13.10  LDFLAGS-$(CONFIG_SunOS) = -Wl,-M -Wl,mapfile-SunOS
   13.11  LDFLAGS-$(CONFIG_Linux) = -Wl,mapfile-GNU
   13.12  LDFLAGS = $(LDFLAGS-y)
    14.1 --- a/tools/libxc/Makefile	Fri Jan 09 16:56:54 2009 +0000
    14.2 +++ b/tools/libxc/Makefile	Mon Jan 12 10:16:05 2009 +0000
    14.3 @@ -62,10 +62,7 @@ CFLAGS-$(CONFIG_Linux) += -D_GNU_SOURCE
    14.4  # libraries.
    14.5  #CFLAGS   += -DVALGRIND -O0 -ggdb3
    14.6  
    14.7 -# Get gcc to generate the dependencies for us.
    14.8 -CFLAGS   += -Wp,-MD,.$(@F).d
    14.9  LDFLAGS  += -L.
   14.10 -DEPS     = .*.d
   14.11  
   14.12  CTRL_LIB_OBJS := $(patsubst %.c,%.o,$(CTRL_SRCS-y))
   14.13  CTRL_PIC_OBJS := $(patsubst %.c,%.opic,$(CTRL_SRCS-y))
    15.1 --- a/tools/misc/Makefile	Fri Jan 09 16:56:54 2009 +0000
    15.2 +++ b/tools/misc/Makefile	Mon Jan 12 10:16:05 2009 +0000
    15.3 @@ -47,7 +47,7 @@ install: build
    15.4  
    15.5  .PHONY: clean
    15.6  clean:
    15.7 -	$(RM) *.o $(TARGETS) *~
    15.8 +	$(RM) *.o $(TARGETS) *~ $(DEPS)
    15.9  	set -e; for d in $(SUBDIRS); do $(MAKE) -C $$d clean; done
   15.10  
   15.11  %.o: %.c $(HDRS) Makefile
   15.12 @@ -55,3 +55,5 @@ clean:
   15.13  
   15.14  xenperf xenpm: %: %.o Makefile
   15.15  	$(CC) $(CFLAGS) -o $@ $< $(LDFLAGS) $(LDFLAGS_libxenctrl)
   15.16 +
   15.17 +-include $(DEPS)
    16.1 --- a/tools/pygrub/Makefile	Fri Jan 09 16:56:54 2009 +0000
    16.2 +++ b/tools/pygrub/Makefile	Mon Jan 12 10:16:05 2009 +0000
    16.3 @@ -22,4 +22,6 @@ endif
    16.4  
    16.5  .PHONY: clean
    16.6  clean:
    16.7 -	rm -rf build tmp *.pyc *.pyo *.o *.a *~ a.out
    16.8 +	rm -rf build tmp *.pyc *.pyo *.o *.a *~ a.out $(DEPS)
    16.9 +
   16.10 +-include $(DEPS)
    17.1 --- a/tools/python/Makefile	Fri Jan 09 16:56:54 2009 +0000
    17.2 +++ b/tools/python/Makefile	Mon Jan 12 10:16:05 2009 +0000
    17.3 @@ -85,3 +85,6 @@ test:
    17.4  .PHONY: clean
    17.5  clean:
    17.6  	rm -rf build *.pyc *.pyo *.o *.a *~ $(CATALOGS) xen/util/auxbin.pyc
    17.7 +	rm -f $(DEPS)
    17.8 +
    17.9 +-include $(DEPS)
    18.1 --- a/tools/vnet/libxutil/Makefile	Fri Jan 09 16:56:54 2009 +0000
    18.2 +++ b/tools/vnet/libxutil/Makefile	Mon Jan 12 10:16:05 2009 +0000
    18.3 @@ -28,10 +28,6 @@ CFLAGS   += -Werror -fno-strict-aliasing
    18.4  CFLAGS   += -O3
    18.5  #CFLAGS   += -g
    18.6  
    18.7 -# Get gcc to generate the dependencies for us.
    18.8 -CFLAGS   += -Wp,-MD,.$(@F).d
    18.9 -DEPS     = .*.d
   18.10 -
   18.11  MAJOR    := 3.0
   18.12  MINOR    := 0
   18.13  LIB      := libxutil.so 
    19.1 --- a/tools/vtpm/Rules.mk	Fri Jan 09 16:56:54 2009 +0000
    19.2 +++ b/tools/vtpm/Rules.mk	Mon Jan 12 10:16:05 2009 +0000
    19.3 @@ -11,11 +11,6 @@ TOOLS_INSTALL_DIR = $(DESTDIR)/usr/bin
    19.4  # General compiler flags
    19.5  CFLAGS   = -Werror -g3 -I.
    19.6  
    19.7 -# For generating dependencies
    19.8 -CFLAGS	+= -Wp,-MD,.$(@F).d
    19.9 -
   19.10 -DEP_FILES	= .*.d
   19.11 -
   19.12  # Generic project files
   19.13  HDRS	= $(wildcard *.h)
   19.14  SRCS	= $(wildcard *.c)
   19.15 @@ -26,7 +21,7 @@ OBJS	= $(patsubst %.c,%.o,$(SRCS))
   19.16  
   19.17  $(OBJS): $(SRCS)
   19.18  
   19.19 --include $(DEP_FILES)
   19.20 +-include $(DEPS)
   19.21  
   19.22  BUILD_EMULATOR = y
   19.23  
    20.1 --- a/tools/vtpm_manager/Rules.mk	Fri Jan 09 16:56:54 2009 +0000
    20.2 +++ b/tools/vtpm_manager/Rules.mk	Mon Jan 12 10:16:05 2009 +0000
    20.3 @@ -11,11 +11,6 @@ TOOLS_INSTALL_DIR = $(DESTDIR)/usr/bin
    20.4  # General compiler flags
    20.5  CFLAGS	= -Werror -g3 -I.
    20.6  
    20.7 -# For generating dependencies
    20.8 -CFLAGS	+= -Wp,-MD,.$(@F).d
    20.9 -
   20.10 -DEP_FILES	= .*.d
   20.11 -
   20.12  # Generic project files
   20.13  HDRS	= $(wildcard *.h)
   20.14  SRCS	= $(wildcard *.c)
   20.15 @@ -26,7 +21,7 @@ OBJS	= $(patsubst %.c,%.o,$(SRCS))
   20.16  
   20.17  $(OBJS): $(SRCS)
   20.18  
   20.19 --include $(DEP_FILES)
   20.20 +-include $(FILES)
   20.21  
   20.22  # Make sure these are just rules
   20.23  .PHONY : all build install clean
    21.1 --- a/tools/xcutils/Makefile	Fri Jan 09 16:56:54 2009 +0000
    21.2 +++ b/tools/xcutils/Makefile	Mon Jan 12 10:16:05 2009 +0000
    21.3 @@ -14,10 +14,6 @@ include $(XEN_ROOT)/tools/Rules.mk
    21.4  CFLAGS += -Werror
    21.5  CFLAGS += $(CFLAGS_libxenctrl) $(CFLAGS_libxenguest) $(CFLAGS_libxenstore)
    21.6  
    21.7 -# Make gcc generate dependencies.
    21.8 -CFLAGS += -Wp,-MD,.$(@F).d
    21.9 -PROG_DEP = .*.d
   21.10 -
   21.11  PROGRAMS = xc_restore xc_save readnotes lsevtchn
   21.12  
   21.13  LDLIBS   = $(LDFLAGS_libxenctrl) $(LDFLAGS_libxenguest) $(LDFLAGS_libxenstore)
   21.14 @@ -40,6 +36,6 @@ install: build
   21.15  .PHONY: clean
   21.16  clean:
   21.17  	$(RM) *.o $(PROGRAMS)
   21.18 -	$(RM) $(PROG_DEP)
   21.19 +	$(RM) $(DEPS)
   21.20  
   21.21 --include $(PROG_DEP)
   21.22 +-include $(DEPS)
    22.1 --- a/tools/xenmon/Makefile	Fri Jan 09 16:56:54 2009 +0000
    22.2 +++ b/tools/xenmon/Makefile	Mon Jan 12 10:16:05 2009 +0000
    22.3 @@ -38,10 +38,12 @@ install: build
    22.4  
    22.5  .PHONY: clean
    22.6  clean:
    22.7 -	rm -f $(BIN)
    22.8 +	rm -f $(BIN) $(DEPS)
    22.9  
   22.10  
   22.11  %: %.c Makefile
   22.12  	$(CC) $(CFLAGS) $< $(LDFLAGS) -o $@
   22.13  xentrace_%: %.c Makefile
   22.14  	$(CC) $(CFLAGS) $< $(LDFLAGS) -o $@
   22.15 +
   22.16 +-include $(DEPS)
    23.1 --- a/tools/xenpmd/Makefile	Fri Jan 09 16:56:54 2009 +0000
    23.2 +++ b/tools/xenpmd/Makefile	Mon Jan 12 10:16:05 2009 +0000
    23.3 @@ -17,4 +17,6 @@ install: all
    23.4  
    23.5  .PHONY: clean
    23.6  clean:
    23.7 -	$(RM) -f $(BIN)
    23.8 +	$(RM) -f $(BIN) $(DEPS)
    23.9 +
   23.10 +-include $(DEPS)
    24.1 --- a/tools/xenstat/libxenstat/Makefile	Fri Jan 09 16:56:54 2009 +0000
    24.2 +++ b/tools/xenstat/libxenstat/Makefile	Mon Jan 12 10:16:05 2009 +0000
    24.3 @@ -155,4 +155,6 @@ endif
    24.4  .PHONY: clean
    24.5  clean:
    24.6  	rm -f $(LIB) $(SHLIB) $(SHLIB_LINKS) $(OBJECTS-y) \
    24.7 -	      $(BINDINGS) $(BINDINGSRC)
    24.8 +	      $(BINDINGS) $(BINDINGSRC) $(DEPS)
    24.9 +
   24.10 +-include $(DEPS)
    25.1 --- a/tools/xenstat/xentop/Makefile	Fri Jan 09 16:56:54 2009 +0000
    25.2 +++ b/tools/xenstat/xentop/Makefile	Mon Jan 12 10:16:05 2009 +0000
    25.3 @@ -37,4 +37,6 @@ endif
    25.4  
    25.5  .PHONY: clean
    25.6  clean:
    25.7 -	rm -f xentop xentop.o
    25.8 +	rm -f xentop xentop.o $(DEPS)
    25.9 +
   25.10 +-include $(DEPS)
    26.1 --- a/tools/xenstore/Makefile	Fri Jan 09 16:56:54 2009 +0000
    26.2 +++ b/tools/xenstore/Makefile	Mon Jan 12 10:16:05 2009 +0000
    26.3 @@ -8,10 +8,6 @@ CFLAGS += -Werror
    26.4  CFLAGS += -I.
    26.5  CFLAGS += $(CFLAGS_libxenctrl)
    26.6  
    26.7 -# Make gcc generate dependencies.
    26.8 -CFLAGS += -Wp,-MD,.$(@F).d
    26.9 -DEP    = .*.d
   26.10 -
   26.11  CLIENTS := xenstore-exists xenstore-list xenstore-read xenstore-rm xenstore-chmod
   26.12  CLIENTS += xenstore-write xenstore-ls
   26.13  
   26.14 @@ -82,7 +78,7 @@ clean:
   26.15  	rm -f xenstored xs_random xs_stress xs_crashme
   26.16  	rm -f xs_tdb_dump xenstore-control
   26.17  	rm -f xenstore $(CLIENTS)
   26.18 -	$(RM) $(DEP)
   26.19 +	$(RM) $(DEPS)
   26.20  
   26.21  .PHONY: TAGS
   26.22  TAGS:
   26.23 @@ -113,7 +109,7 @@ install: all
   26.24  	$(INSTALL_DATA) xs.h $(DESTDIR)$(INCLUDEDIR)
   26.25  	$(INSTALL_DATA) xs_lib.h $(DESTDIR)$(INCLUDEDIR)
   26.26  
   26.27 --include $(DEP)
   26.28 +-include $(DEPS)
   26.29  
   26.30  # never delete any intermediate files.
   26.31  .SECONDARY:
    27.1 --- a/tools/xentrace/Makefile	Fri Jan 09 16:56:54 2009 +0000
    27.2 +++ b/tools/xentrace/Makefile	Mon Jan 12 10:16:05 2009 +0000
    27.3 @@ -46,9 +46,12 @@ install: build
    27.4  
    27.5  .PHONY: clean
    27.6  clean:
    27.7 -	$(RM) *.a *.so *.o *.rpm $(BIN) $(LIBBIN)
    27.8 +	$(RM) *.a *.so *.o *.rpm $(BIN) $(LIBBIN) $(DEPS)
    27.9  
   27.10  %: %.c $(HDRS) Makefile
   27.11  	$(CC) $(CFLAGS) -o $@ $< $(LDFLAGS)
   27.12  xentrace_%: %.c $(HDRS) Makefile
   27.13  	$(CC) $(CFLAGS) -o $@ $< $(LDFLAGS)
   27.14 +
   27.15 +-include $(DEPS)
   27.16 +
    28.1 --- a/xen/arch/ia64/tools/p2m_foreign/Makefile	Fri Jan 09 16:56:54 2009 +0000
    28.2 +++ b/xen/arch/ia64/tools/p2m_foreign/Makefile	Mon Jan 12 10:16:05 2009 +0000
    28.3 @@ -24,10 +24,6 @@ include $(XEN_ROOT)/tools/Rules.mk
    28.4  CFLAGS += -Werror -ggdb3
    28.5  CFLAGS += -I$(XEN_LIBXC) -I$(XEN_XENSTORE)
    28.6  
    28.7 -# Make gcc generate dependencies.
    28.8 -CFLAGS += -Wp,-MD,.$(@F).d
    28.9 -DEPS = .*.d
   28.10 -
   28.11  PROGRAMS = p2m_foreign
   28.12  LDLIBS   = -L$(XEN_LIBXC) -L$(XEN_XENSTORE) -lxenguest -lxenctrl
   28.13