Makefile.am 3.0 KB
Newer Older
K
Karel Zak 已提交
1 2
## Process this file with automake to produce Makefile.in

3 4
SUBDIRS = virshdata confdata sexpr2xmldata \
  xml2sexprdata xmconfigdata xencapsdata
5

K
Karel Zak 已提交
6
INCLUDES = \
7
	-I$(top_srcdir)/gnulib/lib -I../gnulib/lib \
K
Karel Zak 已提交
8 9
	-I$(top_builddir)/include \
	-I$(top_builddir)/src \
10 11
	-I$(top_srcdir)/include \
	-I$(top_srcdir)/src \
12 13
	$(LIBXML_CFLAGS) \
	$(GNUTLS_CFLAGS) \
14
	$(SASL_CFLAGS) \
15
	$(SELINUX_CFLAGS) \
16
        -D_XOPEN_SOURCE=600 -D_POSIX_C_SOURCE=199506L \
17
        -DGETTEXT_PACKAGE=\"$(PACKAGE)\" \
18
         $(COVERAGE_CFLAGS) \
19 20
         $(WARN_CFLAGS)	\
	 $(LIBVIRT_FEATURES)
21

K
Karel Zak 已提交
22 23
LDADDS = \
	@STATIC_BINARIES@ \
24 25
	$(LIBXML_LIBS) \
        $(GNUTLS_LIBS) \
26
        $(SASL_LIBS) \
27
        $(SELINUX_LIBS) \
28
        $(WARN_CFLAGS) \
29
	../src/libvirt_test.la \
30
	../gnulib/lib/libgnu.la \
31
        $(COVERAGE_LDFLAGS)
K
Karel Zak 已提交
32

33 34 35 36
EXTRA_DIST =		\
	xmlrpcserver.py	\
	test_conf.sh	\
	qemuxml2argvdata \
J
Jim Meyering 已提交
37
	nodeinfodata
K
Karel Zak 已提交
38

39
noinst_PROGRAMS = xmlrpctest xml2sexprtest sexpr2xmltest virshtest conftest \
40
	reconnect xmconfigtest xencapstest qemuxml2argvtest qemuxml2xmltest \
41
        nodeinfotest statstest
42

43
test_scripts = \
44
	daemon-conf \
45
	int-overflow
46

47 48
EXTRA_DIST += $(test_scripts)

49
TESTS = xml2sexprtest sexpr2xmltest virshtest test_conf.sh xmconfigtest \
50
        xencapstest qemuxml2argvtest qemuxml2xmltest nodeinfotest \
51
	statstest $(test_scripts)
52 53 54
if ENABLE_XEN_TESTS
  TESTS += reconnect
endif
K
Karel Zak 已提交
55

J
Jim Meyering 已提交
56 57
path_add = $$abs_top_builddir/src$(PATH_SEPARATOR)$$abs_top_builddir/qemud

58 59 60
# NB, automake < 1.10 does not provide the real
# abs_top_{src/build}dir variables, so don't rely
# on them here. Fake them with 'pwd'
61
TESTS_ENVIRONMENT =				\
J
Jim Meyering 已提交
62 63 64
  abs_top_builddir=`cd '$(top_builddir)'; pwd`	\
  abs_top_srcdir=`cd '$(top_srcdir)'; pwd`	\
  PATH="$(path_add)$(PATH_SEPARATOR)$$PATH"	\
65 66
  $(VG)

67
valgrind:
68
	$(MAKE) check VG="valgrind --quiet --leak-check=full"
69

K
Karel Zak 已提交
70 71 72 73
# Note: xmlrpc.[c|h] is not in libvirt yet
xmlrpctest_SOURCES = \
	xmlrpctest.c \
	testutils.c testutils.h \
74 75
	@top_srcdir@/src/xmlrpc.c \
	@top_srcdir@/src/xmlrpc.h
K
Karel Zak 已提交
76 77 78

xmlrpctest_LDADD = $(LDADDS)

79 80 81 82 83 84 85 86 87 88
xml2sexprtest_SOURCES = \
	xml2sexprtest.c \
	testutils.c testutils.h
xml2sexprtest_LDADD = $(LDADDS)

sexpr2xmltest_SOURCES = \
	sexpr2xmltest.c \
	testutils.c testutils.h
sexpr2xmltest_LDADD = $(LDADDS)

89 90 91 92 93
xmconfigtest_SOURCES = \
	xmconfigtest.c \
	testutils.c testutils.h
xmconfigtest_LDADD = $(LDADDS)

94 95 96 97 98 99 100 101 102 103
qemuxml2argvtest_SOURCES = \
	qemuxml2argvtest.c \
	testutils.c testutils.h
qemuxml2argvtest_LDADD = $(LDADDS)

qemuxml2xmltest_SOURCES = \
	qemuxml2xmltest.c \
	testutils.c testutils.h
qemuxml2xmltest_LDADD = $(LDADDS)

104 105 106 107 108
virshtest_SOURCES = \
	virshtest.c \
	testutils.c testutils.h
virshtest_LDADD = $(LDADDS)

D
Daniel Veillard 已提交
109 110 111 112
conftest_SOURCES = \
	conftest.c
conftest_LDADD = $(LDADDS)

113 114 115 116
xencapstest_SOURCES = \
	xencapstest.c testutils.h testutils.c
xencapstest_LDADD = $(LDADDS)

117 118 119 120
nodeinfotest_SOURCES = \
	nodeinfotest.c testutils.h testutils.c
nodeinfotest_LDADD = $(LDADDS)

121 122 123 124
statstest_SOURCES = \
	statstest.c testutils.h testutils.c
statstest_LDADD = $(LDADDS)

125 126 127 128
reconnect_SOURCES = \
	reconnect.c
reconnect_LDADD = $(LDADDS)

129
CLEANFILES = *.cov *.gcov .libs/*.gcda .libs/*.gcno *.gcno *.gcda