Debian Codegraph @

tools/xenmon/Makefile

raw
1 # Copyright (C) HP Labs, Palo Alto and Fort Collins, 2005
2 # Author: Diwaker Gupta <[email protected]>
3 #
4 # This program is free software; you can redistribute it and/or modify
5 # it under the terms of the GNU General Public License as published by
6 # the Free Software Foundation; under version 2 of the License.
7 #
8 # This program is distributed in the hope that it will be useful,
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 # GNU General Public License for more details.
12
13 XEN_ROOT=$(CURDIR)/../..
14 include $(XEN_ROOT)/tools/Rules.mk
15
16 CFLAGS += $(CFLAGS_libxenevtchn)
17 CFLAGS += $(CFLAGS_libxenctrl)
18 LDLIBS += $(LDLIBS_libxenctrl)
19 LDLIBS += $(LDLIBS_libxenevtchn)
20
21 SCRIPTS = xenmon.py
22
23 .PHONY: all
24 all: build
25
26 .PHONY: build
27 build: xentrace_setmask xenbaked
28
29 .PHONY: install
30 install: build
31 $(INSTALL_DIR) $(DESTDIR)$(sbindir)
32 $(INSTALL_PROG) xenbaked $(DESTDIR)$(sbindir)/xenbaked
33 $(INSTALL_PROG) xentrace_setmask $(DESTDIR)$(sbindir)/xentrace_setmask
34 $(INSTALL_PYTHON_PROG) xenmon.py $(DESTDIR)$(sbindir)/xenmon
35
36 .PHONY: uninstall
37 uninstall:
38 rm -f $(DESTDIR)$(sbindir)/xenbaked
39 rm -f $(DESTDIR)$(sbindir)/xentrace_setmask
40 rm -f $(DESTDIR)$(sbindir)/xenmon
41
42 .PHONY: clean
43 clean:
44 $(RM) -f $(DEPS_RM)
45 $(RM) -f xenbaked xenbaked.o
46 $(RM) -f xentrace_setmask setmask.o
47
48 .PHONY: distclean
49 distclean: clean
50
51 xenbaked: xenbaked.o Makefile
52 $(CC) $(LDFLAGS) $< -o $@ $(LDLIBS) $(APPEND_LDFLAGS)
53
54 xentrace_setmask: setmask.o Makefile
55 $(CC) $(LDFLAGS) $< -o $@ $(LDLIBS) $(APPEND_LDFLAGS)
56
57 -include $(DEPS_INCLUDE)