[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-devel] [PATCH 1/2] libxl: provide "realclean" to remove autogenerated files

This removes even the files committed into the tree.  One consequence is
that it becomes easier to reliably force a total rebuild.

Signed-off-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>

diff -r 841b7e3bd1f9 tools/libxl/Makefile
--- a/tools/libxl/Makefile      Wed Apr 25 11:44:09 2012 +0100
+++ b/tools/libxl/Makefile      Wed Apr 25 11:52:58 2012 +0100
@@ -70,8 +70,9 @@ LIBXL_OBJS += _libxl_types.o libxl_flask
 $(LIBXL_OBJS): CFLAGS += $(CFLAGS_libxenctrl) $(CFLAGS_libxenguest) 
$(CFLAGS_libxenstore) $(CFLAGS_libblktapctl) -include $(XEN_ROOT)/tools/config.h
-AUTOINCS= libxlu_cfg_y.h libxlu_cfg_l.h _libxl_list.h
-AUTOSRCS= libxlu_cfg_y.c libxlu_cfg_l.c
+AUTO_STEMS := $(basename $(wildcard *.[ly]))
+AUTOINCS= $(addsuffix .h, $(AUTO_STEMS)) _libxl_list.h
+AUTOSRCS= $(addsuffix .c, $(AUTO_STEMS))
 LIBXLU_OBJS = libxlu_cfg_y.o libxlu_cfg_l.o libxlu_cfg.o \
        libxlu_disk_l.o libxlu_disk.o libxlu_vif.o libxlu_pci.o
 $(LIBXLU_OBJS): CFLAGS += $(CFLAGS_libxenctrl) # For xentoollog.h
@@ -182,8 +183,10 @@ clean:
        $(RM) -f _*.h *.o *.so* *.a $(CLIENTS) $(DEPS)
        $(RM) -f _*.c *.pyc _libxl_paths.*.tmp
        $(RM) -f testidl.c.new testidl.c
-#      $(RM) -f $(AUTOSRCS) $(AUTOINCS)
 distclean: clean
+realclean: distclean
+       $(RM) -f $(AUTOSRCS) $(AUTOINCS)
 -include $(DEPS)

Xen-devel mailing list



Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.