diff options
author | Vincent Torri <vincent.torri@gmail.com> | 2012-09-09 10:09:02 +0000 |
---|---|---|
committer | Vincent Torri <vincent.torri@gmail.com> | 2012-09-09 10:09:02 +0000 |
commit | 653bf991aef512a17af7bfa9fd25ae17bd475285 (patch) | |
tree | 60edcd5e7a2560229703f13088c2d798005de85e /legacy/eobj | |
parent | 544b81fe60f1b012948c1ffef2d235faed80d34b (diff) |
Eo: let's see if Tom likes this check rule
SVN revision: 76353
Diffstat (limited to 'legacy/eobj')
-rw-r--r-- | legacy/eobj/Makefile.am | 21 | ||||
-rw-r--r-- | legacy/eobj/configure.ac | 37 |
2 files changed, 37 insertions, 21 deletions
diff --git a/legacy/eobj/Makefile.am b/legacy/eobj/Makefile.am index 7c026881fe..765232e221 100644 --- a/legacy/eobj/Makefile.am +++ b/legacy/eobj/Makefile.am | |||
@@ -50,9 +50,6 @@ doc: | |||
50 | 50 | ||
51 | # Unit tests | 51 | # Unit tests |
52 | 52 | ||
53 | if EFL_ENABLE_TESTS | ||
54 | |||
55 | |||
56 | lcov-reset: | 53 | lcov-reset: |
57 | @rm -rf $(top_builddir)/coverage | 54 | @rm -rf $(top_builddir)/coverage |
58 | @find $(top_builddir) -name "*.gcda" -delete | 55 | @find $(top_builddir) -name "*.gcda" -delete |
@@ -69,24 +66,14 @@ check-local: | |||
69 | if EFL_ENABLE_COVERAGE | 66 | if EFL_ENABLE_COVERAGE |
70 | @$(MAKE) lcov-reset | 67 | @$(MAKE) lcov-reset |
71 | endif | 68 | endif |
72 | @./src/tests/eo_suite/eo_suite | 69 | @dirs=`find src/tests -maxdepth 1 -type d \! -name '.*' -printf '%P\n' | sort` ; \ |
70 | for dir in $$dirs ; do \ | ||
71 | ./src/tests/$$dir/$$dir ; \ | ||
72 | done | ||
73 | if EFL_ENABLE_COVERAGE | 73 | if EFL_ENABLE_COVERAGE |
74 | @$(MAKE) lcov-report | 74 | @$(MAKE) lcov-report |
75 | endif | 75 | endif |
76 | 76 | ||
77 | else | ||
78 | |||
79 | lcov-reset: | ||
80 | @echo "reconfigure with --enable-tests" | ||
81 | |||
82 | lcov-report: | ||
83 | @echo "reconfigure with --enable-tests" | ||
84 | |||
85 | check-local: | ||
86 | @echo "reconfigure with --enable-tests" | ||
87 | |||
88 | endif | ||
89 | |||
90 | if EFL_ENABLE_BENCHMARK | 77 | if EFL_ENABLE_BENCHMARK |
91 | 78 | ||
92 | benchmark: | 79 | benchmark: |
diff --git a/legacy/eobj/configure.ac b/legacy/eobj/configure.ac index c7b22288b5..68db785985 100644 --- a/legacy/eobj/configure.ac +++ b/legacy/eobj/configure.ac | |||
@@ -35,7 +35,6 @@ AH_BOTTOM([ | |||
35 | AM_INIT_AUTOMAKE([1.6 dist-bzip2]) | 35 | AM_INIT_AUTOMAKE([1.6 dist-bzip2]) |
36 | m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) | 36 | m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) |
37 | 37 | ||
38 | #lt_cv_deplibs_check_method='pass_all' | ||
39 | AC_LIBTOOL_WIN32_DLL | 38 | AC_LIBTOOL_WIN32_DLL |
40 | define([AC_LIBTOOL_LANG_CXX_CONFIG], [:])dnl | 39 | define([AC_LIBTOOL_LANG_CXX_CONFIG], [:])dnl |
41 | define([AC_LIBTOOL_LANG_F77_CONFIG], [:])dnl | 40 | define([AC_LIBTOOL_LANG_F77_CONFIG], [:])dnl |
@@ -76,6 +75,20 @@ requirements_pc_eo="eina" | |||
76 | 75 | ||
77 | ### Additional options to configure | 76 | ### Additional options to configure |
78 | 77 | ||
78 | AC_ARG_ENABLE([coverage], | ||
79 | [AC_HELP_STRING([--enable-coverage], [enable coverage profiling instrumentation @<:@default=disabled@:>@])], | ||
80 | [ | ||
81 | if test "x${enableval}" = "xyes" ; then | ||
82 | _efl_enable_coverage="yes" | ||
83 | else | ||
84 | _efl_enable_coverage="no" | ||
85 | fi | ||
86 | ], | ||
87 | [_efl_enable_coverage="no"]) | ||
88 | |||
89 | AC_MSG_CHECKING([whether to use profiling instrumentation]) | ||
90 | AC_MSG_RESULT([${_efl_enable_coverage}]) | ||
91 | |||
79 | 92 | ||
80 | ### Checks for programs | 93 | ### Checks for programs |
81 | 94 | ||
@@ -96,6 +109,17 @@ AC_SUBST(pkgconfig_requires_private) | |||
96 | 109 | ||
97 | EFL_CHECK_DOXYGEN([build_doc="yes"], [build_doc="no"]) | 110 | EFL_CHECK_DOXYGEN([build_doc="yes"], [build_doc="no"]) |
98 | 111 | ||
112 | # lcov | ||
113 | |||
114 | if test "x$_efl_enable_coverage" = "xyes" ; then | ||
115 | AC_CHECK_PROG(have_lcov, [lcov], [yes], [no]) | ||
116 | if test "x$have_lcov" = "xno" ; then | ||
117 | _efl_enable_coverage="no" | ||
118 | fi | ||
119 | fi | ||
120 | |||
121 | AM_CONDITIONAL([EFL_ENABLE_COVERAGE], [test "x${_efl_enable_coverage}" = "xyes"]) | ||
122 | |||
99 | 123 | ||
100 | ### Checks for libraries | 124 | ### Checks for libraries |
101 | 125 | ||
@@ -119,6 +143,11 @@ AC_CHECK_HEADERS([stdarg.h]) | |||
119 | 143 | ||
120 | ### Checks for compiler characteristics | 144 | ### Checks for compiler characteristics |
121 | 145 | ||
146 | if test "x$_efl_enable_coverage" = "xyes" ; then | ||
147 | EO_CFLAGS="${EO_CFLAGS} -fprofile-arcs -ftest-coverage" | ||
148 | EO_LIBS="${EO_LIBS} -lgcov" | ||
149 | fi | ||
150 | |||
122 | 151 | ||
123 | ### Checks for linker characteristics | 152 | ### Checks for linker characteristics |
124 | 153 | ||
@@ -136,8 +165,6 @@ AC_SUBST([lt_enable_auto_import]) | |||
136 | 165 | ||
137 | ### Unit tests, coverage and benchmarking | 166 | ### Unit tests, coverage and benchmarking |
138 | 167 | ||
139 | EFL_CHECK_TESTS([eina], [enable_tests="yes"], [enable_tests="no"]) | ||
140 | |||
141 | EFL_CHECK_BENCHMARK([enable_benchmark="yes"], [enable_benchmark="no"]) | 168 | EFL_CHECK_BENCHMARK([enable_benchmark="yes"], [enable_benchmark="no"]) |
142 | 169 | ||
143 | AC_SUBST([requirements_pc_eo]) | 170 | AC_SUBST([requirements_pc_eo]) |
@@ -185,7 +212,9 @@ echo | |||
185 | echo "Configuration Options Summary:" | 212 | echo "Configuration Options Summary:" |
186 | echo | 213 | echo |
187 | echo " Documentation........: ${build_doc}" | 214 | echo " Documentation........: ${build_doc}" |
188 | echo " Unit Tests...........: ${enable_tests} (Coverage: ${efl_enable_coverage})" | 215 | echo " Unit Tests...........:" |
216 | echo " build..............: make check" | ||
217 | echo " coverage...........: ${_efl_enable_coverage}" | ||
189 | echo " Examples.............: ${enable_build_examples}" | 218 | echo " Examples.............: ${enable_build_examples}" |
190 | echo " Benchmark............: ${enable_benchmark}" | 219 | echo " Benchmark............: ${enable_benchmark}" |
191 | echo | 220 | echo |