1 include $(top_srcdir)/common/check.mak
3 CHECK_REGISTRY = $(top_builddir)/tests/check/test-registry.reg
5 GST_TOOLS_DIR = $(top_builddir)/tools
7 REGISTRY_ENVIRONMENT = \
8 GST_REGISTRY=$(CHECK_REGISTRY)
11 GST_STATE_IGNORE_ELEMENTS="$(STATE_IGNORE_ELEMENTS)" \
12 $(REGISTRY_ENVIRONMENT) \
13 GST_PLUGIN_SCANNER=$(top_builddir)/libs/gst/helpers/gst-plugin-scanner \
14 GST_PLUGIN_SYSTEM_PATH= \
15 GST_PLUGIN_PATH=$(top_builddir)/plugins
17 plugindir = $(libdir)/gstreamer-@GST_MAJORMINOR@
19 # override to _not_ install the test plugins
20 install-pluginLTLIBRARIES:
22 # the core dumps of some machines have PIDs appended, test registry and
24 CLEANFILES = core core.* test-registry.* *.gcno *.gcda
26 SUPPRESSIONS = $(top_srcdir)/common/gst.supp
28 clean-local: clean-local-check
31 PARSE_CHECKS = pipelines/parse-disabled
33 PARSE_CHECKS = pipelines/simple-launch-lines pipelines/cleanup pipelines/parse-launch
36 # Do not run the abi test in case any option which causes the API to change has
38 if !GST_DISABLE_LOADSAVE
39 if !GST_DISABLE_REGISTRY
41 ABI_CHECKS = gst/gstabi
47 CXX_CHECKS = gst/gstcpp libs/gstlibscpp
52 # if it's calling gst_element_factory_make(), it will probably not work without
54 if GST_DISABLE_REGISTRY
62 gst/gstelementfactory \
132 libs/gstnetclientclock \
133 libs/gstnettimeprovider \
141 # elements to ignore for the state tests
142 # STATE_IGNORE_ELEMENTS =
144 TESTS = $(check_PROGRAMS)
154 gst/struct_x86_64.h \
158 libs/struct_ppc32.h \
159 libs/struct_ppc64.h \
160 libs/struct_sparc.h \
164 libs/test_transform.c
166 AM_CFLAGS = $(GST_OBJ_CFLAGS) -UG_DISABLE_ASSERT -UG_DISABLE_CAST_CHECKS
167 AM_CXXFLAGS = $(GST_OBJ_CXXFLAGS) -UG_DISABLE_ASSERT -UG_DISABLE_CAST_CHECKS
168 LDADD = $(top_builddir)/libs/gst/check/libgstcheck-@GST_MAJORMINOR@.la \
169 $(top_builddir)/libs/gst/base/libgstbase-@GST_MAJORMINOR@.la \
172 gst_gstcpp_SOURCES = gst/gstcpp.cc
174 libs_gstlibscpp_SOURCES = libs/gstlibscpp.cc
176 gst_gstutils_LDADD = $(LDADD) $(GSL_LIBS) $(GMP_LIBS)
181 $(top_builddir)/libs/gst/dataprotocol/libgstdataprotocol-@GST_MAJORMINOR@.la \
184 elements_fdsrc_CFLAGS=$(GST_OBJ_CFLAGS) $(AM_CFLAGS) \
185 -DTESTFILE=\"$(top_srcdir)/configure.ac\"
186 elements_filesrc_CFLAGS=$(GST_OBJ_CFLAGS) $(AM_CFLAGS) \
187 -DTESTFILE=\"$(top_srcdir)/configure.ac\"
189 libs_controller_LDADD = \
190 $(top_builddir)/libs/gst/controller/libgstcontroller-@GST_MAJORMINOR@.la \
192 libs_gstnetclientclock_LDADD = \
193 $(top_builddir)/libs/gst/net/libgstnet-@GST_MAJORMINOR@.la \
195 libs_gstnettimeprovider_LDADD = \
196 $(top_builddir)/libs/gst/net/libgstnet-@GST_MAJORMINOR@.la \
200 # these just need valgrind fixing, period
204 pipelines/parse-launch
209 # these need fixing because the threads cause segfaults under valgrind
214 VALGRIND_TESTS_DISABLE = \
219 # indexers does not get tested yet
223 libs/gst/controller \
225 libs/gst/dataprotocol \
228 COVERAGE_FILES = $(foreach dir,$(COVERAGE_DIRS),$(wildcard $(top_builddir)/$(dir)/*.gcov))
229 COVERAGE_FILES_REL = $(subst $(top_builddir)/,,$(COVERAGE_FILES))
230 COVERAGE_OUT_FILES = $(foreach dir,$(COVERAGE_DIRS),$(wildcard $(top_builddir)/$(dir)/*.gcov.out))
231 COVERAGE_OUT_FILES_REL = $(subst $(top_builddir)/,,$(COVERAGE_OUT_FILES))
234 echo $(COVERAGE_FILES)
235 echo $(COVERAGE_FILES_REL)
239 # we rebuild a registry and do gst-inspect so that all the get/set codepaths
242 for file in `find $(top_builddir) -name '*.gcda'`; do rm $$file; done
243 -rm $(CHECK_REGISTRY)
244 echo "Inspecting all elements"
245 for e in `$(GST_INSPECT) | head -n -2 | cut -d: -f2`; do $(GST_INSPECT) $$e > /dev/null 2>&1; done
250 echo "You need to configure with --enable-gcov to get coverage data"
256 for dir in $(COVERAGE_DIRS); do \
257 mkdir -p coverage/$$dir; \
258 make -C $(top_builddir)/$$dir gcov; \
260 for dir in $(COVERAGE_DIRS); do \
261 files="`ls $(top_builddir)/$$dir/*.gcov.out 2> /dev/null`"; \
262 if test ! -z "$$files"; then \
263 perl $(top_srcdir)/common/coverage/coverage-report.pl \
264 $(top_builddir)/$$dir/*.gcov.out > \
265 coverage/$$dir/index.xml; \
266 xsltproc $(top_srcdir)/common/coverage/coverage-report.xsl \
267 coverage/$$dir/index.xml > coverage/$$dir/index.html; \
271 for file in $(COVERAGE_FILES_REL); do \
272 echo Generating coverage/$$file.html; \
273 perl $(top_srcdir)/common/coverage/coverage-report-entry.pl \
274 $(top_builddir)/$$file > coverage/$$file.html; \