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