ia64/xen-unstable

view tools/blktap2/lvm/Makefile @ 19667:241607f414c8

blktap2: fix makefile of blktap2

- clean up to use SUBDIRS-y
- With parallel make, libvhd might not be created before
link. guarantee it.
- use LDFLAGS for link which is set by upper level makefiles.

Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
author Keir Fraser <keir.fraser@citrix.com>
date Thu May 28 10:02:57 2009 +0100 (2009-05-28)
parents 1c627434605e
children
line source
1 XEN_ROOT = ../../../
2 BLKTAP_ROOT := ../
3 include $(XEN_ROOT)/tools/Rules.mk
5 ifeq ($(LVM_UTIL_TEST),y)
6 TEST := lvm-util
7 endif
9 CFLAGS += -Werror
10 CFLAGS += -Wno-unused
11 CFLAGS += -I../include
12 CFLAGS += -D_GNU_SOURCE
14 ifeq ($(CONFIG_X86_64),y)
15 CFLAGS += -fPIC
16 endif
18 # Get gcc to generate the dependencies for us.
19 CFLAGS += -Wp,-MD,.$(@F).d
20 DEPS = .*.d
22 LVM-OBJS := lvm-util.o
24 all: build
26 build: $(TEST) $(LVM-OBJS)
28 install: all
30 lvm-util: lvm-util.o
31 $(CC) $(CFLAGS) -DLVM_UTIL $(LDFLAGS) -o lvm-util lvm-util.c
33 clean:
34 rm -rf *.o *~ $(DEPS) $(IBIN)
36 .PHONY: all build clean install lvm-util
38 -include $(DEPS)