* V2 parser errors now set appropriate mime types for the encapsulated packet
[third_party/subunit] / Makefile.am
1 EXTRA_DIST =  \
2         .bzrignore \
3         Apache-2.0 \
4         BSD \
5         INSTALL \
6         Makefile.am \
7         NEWS \
8         README \
9         all_tests.py \
10         c++/README \
11         c/README \
12         c/check-subunit-0.9.3.patch \
13         c/check-subunit-0.9.5.patch \
14         c/check-subunit-0.9.6.patch \
15         perl/Makefile.PL.in \
16         perl/lib/Subunit.pm \
17         perl/lib/Subunit/Diff.pm \
18         perl/subunit-diff \
19         python/iso8601/LICENSE \
20         python/iso8601/README \
21         python/iso8601/README.subunit \
22         python/iso8601/setup.py \
23         python/iso8601/test_iso8601.py \
24         python/subunit/tests/__init__.py \
25         python/subunit/tests/sample-script.py \
26         python/subunit/tests/sample-two-script.py \
27         python/subunit/tests/test_chunked.py \
28         python/subunit/tests/test_details.py \
29         python/subunit/tests/test_progress_model.py \
30         python/subunit/tests/test_subunit_filter.py \
31         python/subunit/tests/test_run.py \
32         python/subunit/tests/test_subunit_stats.py \
33         python/subunit/tests/test_subunit_tags.py \
34         python/subunit/tests/test_tap2subunit.py \
35         python/subunit/tests/test_test_protocol.py \
36         python/subunit/tests/test_test_protocol2.py \
37         python/subunit/tests/test_test_results.py \
38         setup.py \
39         shell/README \
40         shell/share/subunit.sh \
41         shell/subunit-ui.patch \
42         shell/tests/test_function_output.sh \
43         shell/tests/test_source_library.sh
44
45 ACLOCAL_AMFLAGS = -I m4
46
47 include_subunitdir = $(includedir)/subunit
48
49 dist_bin_SCRIPTS = \
50         filters/subunit-1to2 \
51         filters/subunit-2to1 \
52         filters/subunit-filter \
53         filters/subunit-ls \
54         filters/subunit-notify \
55         filters/subunit-stats \
56         filters/subunit-tags \
57         filters/subunit2csv \
58         filters/subunit2gtk \
59         filters/subunit2junitxml \
60         filters/subunit2pyunit \
61         filters/tap2subunit
62
63 TESTS = $(check_PROGRAMS)
64
65 ## install libsubunit.pc
66 pcdatadir = $(libdir)/pkgconfig
67 pcdata_DATA = \
68         libsubunit.pc \
69         libcppunit_subunit.pc
70
71 pkgpython_PYTHON = \
72         python/subunit/__init__.py \
73         python/subunit/chunked.py \
74         python/subunit/details.py \
75         python/subunit/filters.py \
76         python/subunit/iso8601.py \
77         python/subunit/progress_model.py \
78         python/subunit/run.py \
79         python/subunit/v2.py \
80         python/subunit/test_results.py
81
82 lib_LTLIBRARIES = libsubunit.la
83 lib_LTLIBRARIES +=  libcppunit_subunit.la
84
85 include_subunit_HEADERS = \
86         c/include/subunit/child.h \
87         c++/SubunitTestProgressListener.h
88
89 check_PROGRAMS = \
90         c/tests/test_child
91
92 libsubunit_la_SOURCES = \
93         c/lib/child.c \
94         c/include/subunit/child.h
95
96 libcppunit_subunit_la_SOURCES = \
97         c++/SubunitTestProgressListener.cpp \
98         c++/SubunitTestProgressListener.h
99
100 tests_LDADD = @CHECK_LIBS@ $(top_builddir)/libsubunit.la
101 c_tests_test_child_CFLAGS = -I$(top_srcdir)/c/include $(SUBUNIT_CFLAGS) @CHECK_CFLAGS@
102 c_tests_test_child_LDADD = $(tests_LDADD)
103
104
105 all-local: perl/Makefile
106         $(MAKE) -C perl all
107
108 check-local: perl/Makefile
109         $(MAKE) -C perl check
110         SHELL_SHARE='$(top_srcdir)/shell/share/' \
111         PYTHONPATH='$(abs_top_srcdir)/python':'$(abs_top_srcdir)':${PYTHONPATH} \
112         $(PYTHON) -m testtools.run all_tests.test_suite
113
114 clean-local:
115         find . -type f -name "*.pyc" -exec rm {} ';'
116         rm -f perl/Makefile
117
118 # Remove perl dir for VPATH builds.
119 distclean-local:
120         -rmdir perl > /dev/null
121         -rm perl/Makefile.PL > /dev/null
122
123 install-exec-local: perl/Makefile
124         $(MAKE) -C perl install
125
126 mostlyclean-local:
127         rm -rf perl/blib
128         rm -rf perl/pm_to_blib
129
130 # 'uninstall' perl files during distcheck
131 uninstall-local:
132         if [ "_inst" = `basename ${prefix}` ]; then \
133           $(MAKE) -C perl uninstall_distcheck; \
134             rm -f "$(DESTDIR)$(bindir)"/subunit-diff; \
135         fi
136
137 # The default for MakeMaker; can be overridden by exporting
138 INSTALLDIRS ?= site
139
140 perl/Makefile: perl/Makefile.PL
141         mkdir -p perl
142         cd perl && perl Makefile.PL INSTALLDIRS=${INSTALLDIRS}
143         -rm perl/Makefile.old > /dev/null