tizen 2.4 release
[external/libjson-glib.git] / Makefile.am
1 ACLOCAL_AMFLAGS = -I build/autotools
2
3 EXTRA_DIST =
4
5 SUBDIRS = json-glib build po
6
7 DISTCHECK_CONFIGURE_FLAGS = --enable-man --enable-maintainer-flags --enable-introspection
8
9 dist-hook:
10         @if test -d "$(srcdir)/.git"; then \
11           echo Generating ChangeLog ; \
12           ( cd "$(srcdir)" \
13             && $(top_srcdir)/build/missing --run git log --stat ) > ChangeLog.tmp \
14           && mv -f ChangeLog.tmp $(top_distdir)/ChangeLog \
15           || ( rm -f ChangeLog.tmp; \
16                echo Failed to generate ChangeLog >&2 ); \
17         else \
18           echo A git checkout is required to generate a ChangeLog >&2; \
19         fi
20
21 if ENABLE_GCOV
22 # use recursive makes in order to ignore errors during check/perf
23 lcov:
24         -$(MAKE) $(AM_MAKEFLAGS) check
25         $(MAKE) $(AM_MAKEFLAGS) genlcov
26
27 # we have to massage the lcov.info file slightly to hide the effect of libtool
28 # placing the objects files in the .libs/ directory separate from the *.c
29 genlcov:
30         $(LTP) --directory $(top_builddir) --capture --output-file json-lcov.info --test-name JSON_TEST --no-checksum
31         $(SED) -e 's#.libs/##' < json-lcov.info > json-lcov.info.tmp
32         LANG=C $(LTP_GENHTML) --prefix $(top_builddir) --output-directory json-lcov --title "JSON-GLib Code Coverage" --show-details json-lcov.info.tmp
33         rm -f json-lcov.info.tmp
34
35 lcov-clean:
36         -$(LTP) --directory $(top_builddir) -z
37         -$(RM) -rf json-lcov.info json-lcov
38 else
39 lcov genlcov lcov-clean:
40         @echo You need to configure JSON-GLib with support for gcov enabled.
41         @echo e.g., ./configure --enable-gcov
42 endif
43
44 .PHONY: lcov genlcov lcov-clean