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

[Xen-devel] [PATCH 8 of 8 RESEND] blktap3/vhd: Introduce Makefile to in the VHD module that calls the libvhd Makefile



This patch introduces the Makefile that builds the VHD module. Since the vhd/
directory is not yet populated, it simply calls the vhd/lib/ Makefile. This
file is based on the existing blktap2 file.

Signed-off-by: Thanos Makatos <thanos.makatos@xxxxxxxxxx>

diff --git a/tools/blktap2/vhd/Makefile b/tools/blktap3/vhd/Makefile
copy from tools/blktap2/vhd/Makefile
copy to tools/blktap3/vhd/Makefile
--- a/tools/blktap2/vhd/Makefile
+++ b/tools/blktap3/vhd/Makefile
@@ -5,45 +5,17 @@ include $(XEN_ROOT)/tools/Rules.mk
 SUBDIRS-y         :=
 SUBDIRS-y         += lib
 
-IBIN               = vhd-util vhd-update
-INST_DIR           = $(SBINDIR)
+all: subdirs-all
 
-CFLAGS            += -Werror
-CFLAGS            += -Wno-unused
-CFLAGS            += -I../include
-CFLAGS            += -D_GNU_SOURCE
-
-ifeq ($(CONFIG_X86_64),y)
-CFLAGS            += -fPIC
-endif
-
-ifeq ($(VHD_STATIC),y)
-CFLAGS            += -static
-endif
-
-LIBS              := -Llib -lvhd
-
-all: subdirs-all build
-
-build: $(IBIN)
-
-LIBS_DEPENDS     := lib/libvhd.so lib/vhd.a
-$(LIBS_DEPENDS):subdirs-all
-
-vhd-util: vhd-util.o $(LIBS_DEPENDS)
-       $(CC) $(LDFLAGS) -o vhd-util vhd-util.o $(LIBS)
-
-vhd-update: vhd-update.o $(LIBS_DEPENDS)
-       $(CC) $(LDFLAGS) -o vhd-update vhd-update.o $(LIBS)
+LIBS_DEPENDS := lib/libvhd.so lib/libvhd.a
+$(LIBS_DEPENDS): subdirs-all
 
 install: all
        $(MAKE) subdirs-install
-       $(INSTALL_DIR) -p $(DESTDIR)$(INST_DIR)
-       $(INSTALL_PROG) $(IBIN) $(DESTDIR)$(INST_DIR)
 
 clean: subdirs-clean
-       rm -rf *.o *~ $(DEPS) $(IBIN)
 
-.PHONY: all build clean install vhd-util vhd-update
+.PHONY: all clean install
 
+# TODO Is this necessary?
 -include $(DEPS)

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

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