daemon: Move TLS initialization to virInitialize
[libvirt/zwu.git] / Makefile.am
blob75cff8ddd96536b1a457b2f3563a076019de1c1c
1 ## Process this file with automake to produce Makefile.in
3 ## Copyright (C) 2005-2011 Red Hat, Inc.
4 ## See COPYING.LIB for the License of this software
6 LCOV = lcov
7 GENHTML = genhtml
9 SUBDIRS = gnulib/lib include src daemon tools docs gnulib/tests \
10   python tests po examples/domain-events/events-c examples/hellolibvirt \
11   examples/dominfo examples/domsuspend examples/python examples/apparmor \
12   examples/xml/nwfilter examples/openauth examples/systemtap
14 ACLOCAL_AMFLAGS = -I m4 -I gnulib/m4
16 XML_EXAMPLES = \
17   $(patsubst $(srcdir)/%,%,$(wildcard $(addprefix $(srcdir)/examples/xml/, \
18                                         test/*.xml storage/*.xml)))
20 EXTRA_DIST = \
21   ChangeLog-old \
22   libvirt.spec libvirt.spec.in \
23   mingw32-libvirt.spec.in \
24   libvirt.pc.in \
25   autobuild.sh \
26   Makefile.nonreentrant \
27   autogen.sh \
28   cfg.mk \
29   examples/domain-events/events-python \
30   $(XML_EXAMPLES)
32 pkgconfigdir = $(libdir)/pkgconfig
33 pkgconfig_DATA = libvirt.pc
35 NEWS: $(top_srcdir)/docs/news.xsl $(top_srcdir)/docs/news.html.in
36         -@(if [ -x $(XSLTPROC) ] ; then                         \
37           $(XSLTPROC) --nonet $(top_srcdir)/docs/news.xsl       \
38              $(top_srcdir)/docs/news.html.in                    \
39            | perl -0777 -pe 's/\n\n+$$/\n/'                     \
40            | perl -pe 's/[ \t]+$$//'                            \
41            > $@-t && mv $@-t $@ ; fi );
43 $(top_srcdir)/HACKING: $(top_srcdir)/docs/hacking1.xsl $(top_srcdir)/docs/hacking2.xsl \
44                        $(top_srcdir)/docs/wrapstring.xsl $(top_srcdir)/docs/hacking.html.in
45         -@(if [ -x $(XSLTPROC) ] ; then \
46            $(XSLTPROC) --nonet $(top_srcdir)/docs/hacking1.xsl $(top_srcdir)/docs/hacking.html.in | \
47            $(XSLTPROC) --nonet $(top_srcdir)/docs/hacking2.xsl - \
48            | perl -0777 -pe 's/\n\n+$$/\n/' \
49            > $@-t && mv $@-t $@ ; fi );
51 rpm: clean
52         @(unset CDPATH ; $(MAKE) dist && rpmbuild -ta $(distdir).tar.gz)
54 check-local: all tests
56 tests:
57         @(cd docs/examples ; $(MAKE) MAKEFLAGS+=--silent tests)
58         @(if [ "$(pythondir)" != "" ] ; then cd python ; \
59           $(MAKE) MAKEFLAGS+=--silent tests ; fi)
61 cov: clean-cov
62         mkdir $(top_builddir)/coverage
63         $(LCOV) -c -o $(top_builddir)/coverage/libvirt.info.tmp \
64           -d $(top_builddir)/src  -d $(top_builddir)/daemon \
65           -d $(top_builddir)/tests
66         $(LCOV) -r $(top_builddir)/coverage/libvirt.info.tmp \
67           -o $(top_builddir)/coverage/libvirt.info
68         rm $(top_builddir)/coverage/libvirt.info.tmp
69         $(GENHTML) --show-details -t "libvirt" -o $(top_builddir)/coverage \
70           --legend $(top_builddir)/coverage/libvirt.info
72 clean-cov:
73         rm -rf $(top_builddir)/coverage
75 MAINTAINERCLEANFILES = .git-module-status
77 # disable this check
78 distuninstallcheck:
80 dist-hook: gen-ChangeLog
82 # Generate the ChangeLog file (with all entries since the switch to git)
83 # and insert it into the directory we're about to use to create a tarball.
84 gen_start_date = 2009-07-04
85 .PHONY: gen-ChangeLog
86 gen-ChangeLog:
87         if test -d .git; then                                   \
88           $(top_srcdir)/build-aux/gitlog-to-changelog           \
89             --since=$(gen_start_date) > $(distdir)/cl-t;        \
90           rm -f $(distdir)/ChangeLog;                           \
91           mv $(distdir)/cl-t $(distdir)/ChangeLog;              \
92         fi