Release 0.41.92
[vala-gnome.git] / Makefile.am
blob508c6618f601de9f4339cb7d71eeabc5bced029e
1 ACLOCAL_AMFLAGS = --install -I m4 ${ACLOCAL_FLAGS}
3 NULL =
5 SUBDIRS = \
6         gee \
7         vala \
8         ccode \
9         codegen \
10         compiler \
11         vapi \
12         tests \
13         doc \
14         gobject-introspection \
15         vapigen \
16         libvaladoc \
17         valadoc \
18         $(NULL)
20 if ENABLE_UNVERSIONED
21 aclocaldir = $(datadir)/aclocal
22 aclocal_DATA = vala.m4
23 endif
25 pkgconfigdir = $(libdir)/pkgconfig
26 pkgconfig_DATA = libvala@PACKAGE_SUFFIX@.pc
28 libvala@PACKAGE_SUFFIX@.pc: libvala.pc
29         cp $< $@
31 .PHONY: bootstrap
32 bootstrap: all
33         find $(top_srcdir) -name "*.vala.stamp" | xargs rm -f
34         $(MAKE) $(AM_MAKEFLAGS) all VALAC=$(abs_top_builddir)/compiler/valac$(EXEEXT) V=$V
36 .PHONY: test
37 test:
38         cd tests && $(MAKE) $(AM_MAKEFLAGS) check
40 #if ENABLE_COVERAGE
41 .PHONY: coverage coverage-report
42 coverage:
43         find $(top_srcdir) -name "*.gcda" | xargs rm -f
44         $(MAKE) $(AM_MAKEFLAGS) bootstrap
45         $(MAKE) $(AM_MAKEFLAGS) test
47 coverage-report: coverage
48         lcov --directory $(top_srcdir) --capture --output-file $(top_builddir)/lcov.info
49         lcov --directory $(top_srcdir) --output-file $(top_builddir)/lcov.info --remove $(top_builddir)/lcov.info "*.c" "*.h" "*.vapi"
50         rm -rf $(top_builddir)/coverage
51         $(mkdir_p) $(top_builddir)/coverage
52         genhtml --title "@PACKAGE_STRING@" --output-directory $(top_builddir)/coverage $(top_builddir)/lcov.info
53 #endif
55 BUILT_SOURCES = $(top_srcdir)/.version
56 $(top_srcdir)/.version: gen-version
57         @true
58 .PHONY: gen-version
59 gen-version:
60         @V=`$(top_srcdir)/build-aux/git-version-gen $(top_srcdir)/.tarball-version` &&                  \
61         if [ -e $(top_srcdir)/.version ] && [ "x`cat $(top_srcdir)/.version`" = "x$$V" ]; then          \
62           true;                                                                                         \
63         else                                                                                            \
64           echo "$$V" > $(top_srcdir)/.version;                                                          \
65         fi
66 dist-hook: gen-ChangeLog
67         echo $(VERSION) > $(distdir)/.tarball-version
69 gen_start_date = 2009-02-25
70 .PHONY: gen-ChangeLog
71 gen-ChangeLog:
72         if test -d .git; then                                           \
73           $(top_srcdir)/build-aux/gitlog-to-changelog                   \
74             --since=$(gen_start_date) > $(distdir)/cl-t;                \
75           rm -f $(distdir)/ChangeLog;                                   \
76           mv $(distdir)/cl-t $(distdir)/ChangeLog;                      \
77         fi
79 CLEANFILES = \
80         libvala@PACKAGE_SUFFIX@.pc \
81         $(NULL)
83 EXTRA_DIST = \
84         ChangeLog.pre-0-4 \
85         ChangeLog.pre-0-5-7 \
86         libvala.pc.in \
87         vala.m4 \
88         .version \
89         build-aux/git-version-gen \
90         build-aux/gitlog-to-changelog \
91         $(NULL)