Eet: remove --enable-coverage option.
Now, coverage is detected with just --enable-tests. Buildbot maintainers : please remove --enable-coverage option to eet (more EFL will be supported later) SVN revision: 73108
This commit is contained in:
parent
5859a1ded5
commit
b415c1dd55
|
@ -36,7 +36,6 @@ m4/ac_path_generic.m4 \
|
||||||
m4/efl_binary.m4 \
|
m4/efl_binary.m4 \
|
||||||
m4/efl_check_funcs.m4 \
|
m4/efl_check_funcs.m4 \
|
||||||
m4/efl_check_libs.m4 \
|
m4/efl_check_libs.m4 \
|
||||||
m4/efl_coverage.m4 \
|
|
||||||
m4/efl_doxygen.m4 \
|
m4/efl_doxygen.m4 \
|
||||||
m4/efl_tests.m4 \
|
m4/efl_tests.m4 \
|
||||||
m4/efl_path_max.m4
|
m4/efl_path_max.m4
|
||||||
|
@ -44,7 +43,7 @@ m4/efl_path_max.m4
|
||||||
pkgconfigdir = $(libdir)/pkgconfig
|
pkgconfigdir = $(libdir)/pkgconfig
|
||||||
pkgconfig_DATA = eet.pc
|
pkgconfig_DATA = eet.pc
|
||||||
|
|
||||||
.PHONY: doc coverage
|
.PHONY: doc
|
||||||
|
|
||||||
# Documentation
|
# Documentation
|
||||||
|
|
||||||
|
@ -56,19 +55,6 @@ doc:
|
||||||
|
|
||||||
if EFL_ENABLE_TESTS
|
if EFL_ENABLE_TESTS
|
||||||
|
|
||||||
check-local:
|
|
||||||
@./src/tests/eet_suite
|
|
||||||
|
|
||||||
else
|
|
||||||
|
|
||||||
check-local:
|
|
||||||
@echo "reconfigure with --enable-tests"
|
|
||||||
|
|
||||||
endif
|
|
||||||
|
|
||||||
# Coverage report
|
|
||||||
|
|
||||||
if EFL_ENABLE_COVERAGE
|
|
||||||
lcov-reset:
|
lcov-reset:
|
||||||
@rm -rf $(top_builddir)/coverage
|
@rm -rf $(top_builddir)/coverage
|
||||||
@find $(top_builddir) -name "*.gcda" -delete
|
@find $(top_builddir) -name "*.gcda" -delete
|
||||||
|
@ -81,20 +67,23 @@ lcov-report:
|
||||||
genhtml -t "$(PACKAGE_STRING)" -o $(top_builddir)/coverage/html $(top_builddir)/coverage/coverage.cleaned.info
|
genhtml -t "$(PACKAGE_STRING)" -o $(top_builddir)/coverage/html $(top_builddir)/coverage/coverage.cleaned.info
|
||||||
@echo "Coverage Report at $(top_builddir)/coverage/html"
|
@echo "Coverage Report at $(top_builddir)/coverage/html"
|
||||||
|
|
||||||
coverage:
|
check-local:
|
||||||
@$(MAKE) lcov-reset
|
@$(MAKE) lcov-reset
|
||||||
@$(MAKE) check
|
@./src/tests/eet_suite
|
||||||
@$(MAKE) lcov-report
|
@$(MAKE) lcov-report
|
||||||
|
|
||||||
|
else
|
||||||
|
|
||||||
|
lcov-reset:
|
||||||
|
@echo "reconfigure with --enable-tests"
|
||||||
|
|
||||||
|
lcov-report:
|
||||||
|
@echo "reconfigure with --enable-tests"
|
||||||
|
|
||||||
|
check-local:
|
||||||
|
@echo "reconfigure with --enable-tests"
|
||||||
|
|
||||||
|
endif
|
||||||
|
|
||||||
clean-local:
|
clean-local:
|
||||||
@rm -rf coverage
|
@rm -rf coverage
|
||||||
else
|
|
||||||
lcov-reset:
|
|
||||||
@echo "reconfigure with --enable-coverage"
|
|
||||||
|
|
||||||
lcov-report:
|
|
||||||
@echo "reconfigure with --enable-coverage"
|
|
||||||
|
|
||||||
coverage:
|
|
||||||
@echo "reconfigure with --enable-tests --enable-coverage"
|
|
||||||
endif
|
|
||||||
|
|
|
@ -186,19 +186,6 @@ AC_ARG_ENABLE([build-examples],
|
||||||
[build_examples="no"])
|
[build_examples="no"])
|
||||||
AM_CONDITIONAL([BUILD_EXAMPLES], [test "x${build_examples}" = "xyes"])
|
AM_CONDITIONAL([BUILD_EXAMPLES], [test "x${build_examples}" = "xyes"])
|
||||||
|
|
||||||
# Unit tests, coverage and benchmarking
|
|
||||||
|
|
||||||
EFL_CHECK_TESTS([enable_tests="yes"], [enable_tests="no"])
|
|
||||||
EFL_CHECK_COVERAGE([${enable_tests}], [enable_coverage="yes"], [enable_coverage="no"])
|
|
||||||
|
|
||||||
if test "x${prefer_assert}" = "xno"; then
|
|
||||||
DEBUG_CFLAGS="-DNDEBUG"
|
|
||||||
else
|
|
||||||
# use debug symbols and set DEBUG if coverage support is enabled
|
|
||||||
DEBUG_CFLAGS="${EFL_DEBUG_CFLAGS}"
|
|
||||||
fi
|
|
||||||
AC_SUBST(DEBUG_CFLAGS)
|
|
||||||
|
|
||||||
|
|
||||||
### Checks for programs
|
### Checks for programs
|
||||||
AC_PROG_CC
|
AC_PROG_CC
|
||||||
|
@ -492,6 +479,11 @@ AC_CHECK_FUNCS(fmemopen open_memstream realpath)
|
||||||
EFL_CHECK_FUNCS([eet], [fnmatch])
|
EFL_CHECK_FUNCS([eet], [fnmatch])
|
||||||
|
|
||||||
|
|
||||||
|
### Unit tests, coverage and benchmarking
|
||||||
|
|
||||||
|
EFL_CHECK_TESTS([eet], [enable_tests="yes"], [enable_tests="no"])
|
||||||
|
|
||||||
|
|
||||||
AC_SUBST([requirements_pc_eet])
|
AC_SUBST([requirements_pc_eet])
|
||||||
AC_SUBST([requirements_libs_eet])
|
AC_SUBST([requirements_libs_eet])
|
||||||
|
|
||||||
|
@ -530,8 +522,7 @@ fi
|
||||||
echo
|
echo
|
||||||
echo " Old eet file format..: ${old_eet_file_format}"
|
echo " Old eet file format..: ${old_eet_file_format}"
|
||||||
echo
|
echo
|
||||||
echo " Tests................: ${enable_tests}"
|
echo " Tests................: ${enable_tests} (Coverage: ${efl_enable_coverage})"
|
||||||
echo " Coverage.............: ${enable_coverage}"
|
|
||||||
echo
|
echo
|
||||||
echo " Build eet............: $have_eet"
|
echo " Build eet............: $have_eet"
|
||||||
echo
|
echo
|
||||||
|
|
|
@ -1,62 +0,0 @@
|
||||||
dnl Copyright (C) 2008 Vincent Torri <vtorri at univ-evry dot fr>
|
|
||||||
dnl That code is public domain and can be freely used or copied.
|
|
||||||
|
|
||||||
dnl Macro that check if coverage support is wanted and, if yes, if
|
|
||||||
dnl lcov is available.
|
|
||||||
|
|
||||||
dnl Usage: EFL_CHECK_COVERAGE(tests [, ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]])
|
|
||||||
dnl The parameter 'tests' is used if a dependency is needed. If set to "yes",
|
|
||||||
dnl the dependency is available.
|
|
||||||
dnl Defines EFL_COVERAGE_CFLAGS and EFL_COVERAGE_LIBS variables
|
|
||||||
dnl Defines the automake conditionnal EFL_ENABLE_COVERAGE
|
|
||||||
|
|
||||||
AC_DEFUN([EFL_CHECK_COVERAGE],
|
|
||||||
[
|
|
||||||
|
|
||||||
dnl configure option
|
|
||||||
|
|
||||||
AC_ARG_ENABLE([coverage],
|
|
||||||
[AC_HELP_STRING([--enable-coverage], [enable coverage profiling instrumentation @<:@default=disabled@:>@])],
|
|
||||||
[
|
|
||||||
if test "x${enableval}" = "xyes" ; then
|
|
||||||
_efl_enable_coverage="yes"
|
|
||||||
else
|
|
||||||
_efl_enable_coverage="no"
|
|
||||||
fi
|
|
||||||
],
|
|
||||||
[_efl_enable_coverage="no"])
|
|
||||||
|
|
||||||
AC_MSG_CHECKING([whether to use profiling instrumentation])
|
|
||||||
AC_MSG_RESULT([$_efl_enable_coverage])
|
|
||||||
|
|
||||||
dnl lcov check
|
|
||||||
|
|
||||||
if test "x$_efl_enable_coverage" = "xyes" && test ! "x$1" = "xyes" ; then
|
|
||||||
AC_MSG_WARN([Coverage report requested but tests not being built, disable profiling instrumentation.])
|
|
||||||
AC_MSG_WARN([Run configure with --enable-tests])
|
|
||||||
_efl_enable_coverage="no"
|
|
||||||
fi
|
|
||||||
|
|
||||||
if test "x$_efl_enable_coverage" = "xyes" ; then
|
|
||||||
AC_CHECK_PROG(have_lcov, [lcov], [yes], [no])
|
|
||||||
if test "x$have_lcov" = "xyes" ; then
|
|
||||||
EFL_COVERAGE_CFLAGS="-fprofile-arcs -ftest-coverage"
|
|
||||||
EFL_COVERAGE_LIBS="-lgcov"
|
|
||||||
# remove any optimisation flag and force debug symbols
|
|
||||||
EFL_DEBUG_CFLAGS="-g -O0 -DDEBUG"
|
|
||||||
else
|
|
||||||
AC_MSG_WARN([lcov is not found, disable profiling instrumentation])
|
|
||||||
_efl_enable_coverage="no"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
dnl Substitution
|
|
||||||
AC_SUBST(EFL_COVERAGE_CFLAGS)
|
|
||||||
AC_SUBST(EFL_COVERAGE_LIBS)
|
|
||||||
|
|
||||||
AM_CONDITIONAL(EFL_ENABLE_COVERAGE, test "x${_efl_enable_coverage}" = "xyes")
|
|
||||||
|
|
||||||
AS_IF([test "x$_efl_enable_coverage" = "xyes"], [$2], [$3])
|
|
||||||
])
|
|
||||||
|
|
||||||
dnl End of efl_coverage.m4
|
|
|
@ -1,14 +1,16 @@
|
||||||
dnl Copyright (C) 2008 Vincent Torri <vtorri at univ-evry dot fr>
|
dnl Copyright (C) 2008-2012 Vincent Torri <vtorri at univ-evry dot fr>
|
||||||
dnl That code is public domain and can be freely used or copied.
|
dnl That code is public domain and can be freely used or copied.
|
||||||
|
|
||||||
dnl Macro that check if tests programs are wanted and if yes, if
|
dnl Macro that check if tests programs are wanted and if yes, if
|
||||||
dnl the Check library is available.
|
dnl the Check library is available.
|
||||||
|
dnl the lcov program is available.
|
||||||
|
|
||||||
dnl Usage: EFL_CHECK_TESTS([ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]])
|
dnl Usage: EFL_CHECK_TESTS(EFL[, ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]])
|
||||||
dnl Define the automake conditionnal EFL_ENABLE_TESTS
|
dnl Define the automake conditionnal EFL_ENABLE_TESTS
|
||||||
|
|
||||||
AC_DEFUN([EFL_CHECK_TESTS],
|
AC_DEFUN([EFL_CHECK_TESTS],
|
||||||
[
|
[
|
||||||
|
m4_pushdef([UPEFL], m4_translit([$1], [-a-z], [_A-Z]))dnl
|
||||||
|
|
||||||
dnl configure option
|
dnl configure option
|
||||||
|
|
||||||
|
@ -35,9 +37,29 @@ if test "x${_efl_enable_tests}" = "xyes" ; then
|
||||||
[_efl_enable_tests="no"])
|
[_efl_enable_tests="no"])
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
efl_enable_coverage="no"
|
||||||
|
if test "x${_efl_enable_tests}" = "xyes" ; then
|
||||||
|
AC_CHECK_PROG(have_lcov, [lcov], [yes], [no])
|
||||||
|
if test "x$have_lcov" = "xyes" ; then
|
||||||
|
m4_defn([UPEFL])[]_CFLAGS="${m4_defn([UPEFL])[]_CFLAGS} -fprofile-arcs -ftest-coverage"
|
||||||
|
m4_defn([UPEFL])[]_LIBS="${m4_defn([UPEFL])[]_LIBS} -lgcov"
|
||||||
|
# remove any optimisation flag and force debug symbols
|
||||||
|
m4_defn([UPEFL])[]_CFLAGS="${m4_defn([UPEFL])[]_CFLAGS} -g -O0 -DDEBUG"
|
||||||
|
efl_enable_coverage="yes"
|
||||||
|
else
|
||||||
|
AC_MSG_WARN([lcov is not found, disable profiling instrumentation])
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
dnl Substitution
|
||||||
|
AC_SUBST(EFL_COVERAGE_CFLAGS)
|
||||||
|
AC_SUBST(EFL_COVERAGE_LIBS)
|
||||||
|
|
||||||
AM_CONDITIONAL(EFL_ENABLE_TESTS, test "x${_efl_enable_tests}" = "xyes")
|
AM_CONDITIONAL(EFL_ENABLE_TESTS, test "x${_efl_enable_tests}" = "xyes")
|
||||||
|
|
||||||
AS_IF([test "x$_efl_enable_tests" = "xyes"], [$1], [$2])
|
AS_IF([test "x$_efl_enable_tests" = "xyes"], [$2], [$3])
|
||||||
|
|
||||||
|
m4_popdef([UPEFL])
|
||||||
])
|
])
|
||||||
|
|
||||||
dnl End of efl_tests.m4
|
dnl End of efl_tests.m4
|
||||||
|
|
Loading…
Reference in New Issue