ia64/xen-unstable

view tools/xcutils/Makefile @ 16894:b9004e222fde

Move generation of public header hierarchy into the tools.

This patch merges the two versions of public header generation
currently used in the build into one.

Signed-off-by: Bastian Blank <waldi@debian.org>
author Keir Fraser <keir.fraser@citrix.com>
date Sat Jan 26 10:38:44 2008 +0000 (2008-01-26)
parents 6ed9b42d1ec4
children 221b867ee084
line source
1 #
2 # tools/xcutils/Makefile
3 #
4 # This file is subject to the terms and conditions of the GNU General
5 # Public License. See the file "COPYING" in the main directory of
6 # this archive for more details.
7 #
8 # Copyright (C) 2005 by Christian Limpach
9 #
11 XEN_ROOT = ../..
12 include $(XEN_ROOT)/tools/Rules.mk
14 PROGRAMS_INSTALL_DIR = $(LIBDIR)/xen/bin
16 INCLUDES += -I $(XEN_LIBXC) -I $(XEN_XENSTORE) -I$(XEN_INCLUDE)
18 CFLAGS += -Werror
19 CFLAGS += $(INCLUDES)
21 # Make gcc generate dependencies.
22 CFLAGS += -Wp,-MD,.$(@F).d
23 PROG_DEP = .*.d
25 PROGRAMS = xc_restore xc_save readnotes
27 LDLIBS = -L$(XEN_LIBXC) -L$(XEN_XENSTORE) -lxenguest -lxenctrl -lxenstore
29 .PHONY: all
30 all: build
32 .PHONY: build
33 build: $(PROGRAMS)
35 $(PROGRAMS): %: %.o
36 $(CC) $(CFLAGS) $(LDFLAGS) $^ $(LDLIBS) -o $@
38 .PHONY: install
39 install: build
40 [ -d $(DESTDIR)$(PROGRAMS_INSTALL_DIR) ] || \
41 $(INSTALL_DIR) $(DESTDIR)$(PROGRAMS_INSTALL_DIR)
42 $(INSTALL_PROG) $(PROGRAMS) $(DESTDIR)$(PROGRAMS_INSTALL_DIR)
45 .PHONY: clean
46 clean:
47 $(RM) *.o $(PROGRAMS)
48 $(RM) $(PROG_DEP)
50 -include $(PROG_DEP)