Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ISC Open Source Projects
Kea
Commits
1949bb3a
Commit
1949bb3a
authored
Jan 31, 2018
by
Tomek Mrugalski
🛰
Browse files
[master] Merge branch 'github43' (Makefile.am improvements)
parents
d3d22fd4
33b06cb0
Changes
1
Hide whitespace changes
Inline
Side-by-side
Makefile.am
View file @
1949bb3a
...
...
@@ -10,6 +10,7 @@ GENHTML=@GENHTML@
DISTCHECK_GTEST_CONFIGURE_FLAG
=
@DISTCHECK_GTEST_CONFIGURE_FLAG@
DISTCHECK_CRYPTO_CONFIGURE_FLAG
=
@DISTCHECK_CRYPTO_CONFIGURE_FLAG@
DISTCHECK_BOOST_CONFIGURE_FLAG
=
@DISTCHECK_BOOST_CONFIGURE_FLAG@
OVERALL_COVERAGE_DIR
=
$(abs_top_builddir)
/coverage-cpp-html
DISTCHECK_LOG4CPLUS_CONFIGURE_FLAG
=
@DISTCHECK_LOG4CPLUS_CONFIGURE_FLAG@
DISTCHECK_KEA_SHELL_CONFIGURE_FLAG
=
@DISTCHECK_KEA_SHELL_CONFIGURE_FLAG@
...
...
@@ -56,47 +57,61 @@ endif
clean-cpp-coverage
:
@
if
[
$(USE_LCOV)
=
yes
]
;
then
\
$(LCOV)
--directory
.
--zerocounters
;
\
rm
-rf
$(
abs_top_srcdir)
/coverage-cpp-html/
;
\
rm
-rf
$(
OVERALL_COVERAGE_DIR)
;
\
else
\
echo
"C++ code coverage not enabled at configuration time."
;
\
echo
"Use: ./configure --with-lcov"
;
\
fi
perform-coverage
:
check
perform-coverage
:
find src
-mindepth
2
-maxdepth
2
-type
d | xargs
-I
{}
bash
-c
"cd {}; make check || true"
report-cpp-coverage
:
if
HAVE_BOTAN
BOTAN_PATH
=
botan/
\*
else
BOTAN_PATH
=
endif
if
HAVE_OPENSSL
OPENSSL_PATH
=
openssl/
\*
else
OPENSSL_PATH
=
endif
@if
[
$(USE_LCOV)
=
yes
]
;
then
\
$(LCOV)
--capture
--directory
.
--output-file
all.info
;
\
$(LCOV)
--capture
--directory
.
\
--ignore-errors
gcov,source,graph
\
--output-file
all.info
;
\
$(LCOV)
--remove
all.info
\
c++/4.4
\*
/
\*
\
c++/4.4
\*
/backward/
\*
\
c++/4.4
\*
/bits/
\*
\
c++/4.4
\*
/ext/
\*
\
c++/4.4
\*
/
\*
-
\*
/bits/
\*
\
c++/
*
\
boost/
\*
\
if
HAVE_BOTAN
botan/\*
\
endif
gtest/\*
\
include/\*
\
lib/\eval/\*
\
log4cplus/\*
\
if
HAVE_OPENSSL
openssl/
\*
\
endif
unittests/\*
\
\*
_unittests.cc
\
\*
_unittest.cc
\
\*
_unittests.h
\
--output
report.info
;
\
sed
-e
"s|
$(abs_top_srcdir)
|
$(abs_top_builddir)
|g"
< report.info
>
report.info.2
;
\
$(GENHTML)
--legend
-o
$(abs_top_builddir)
/coverage-cpp-html report.info.2
;
\
echo
"Generated C++ Code Coverage report in HTML at
$(abs_top_builddir)
/coverage-cpp-html"
;
\
tests/\*
\
testutils/\*
\
valgrind/\*
\
$(BOTAN_PATH)
\
$(OPENSSL_PATH)
\
--ignore-errors
gcov,source,graph
\
--output
report.info;
\
sed
--in-place
--expression
"s|$(abs_top_srcdir)|$(abs_top_builddir)|g"
report.info;
\
"$(GENHTML)"
--frames
--show-details
--title
'Kea code coverage report'
--legend
\
--function-coverage
--ignore-errors
source
--demangle-cpp
\
--output
"$(OVERALL_COVERAGE_DIR)"
report.info;
\
printf
"Generated C++ code coverage report in HTML at %s.\n"
"$(OVERALL_COVERAGE_DIR)"
;
\
else
\
echo
"C++ code coverage not enabled at configuration time."
;
\
echo "Use
:
./configure --with-lcov" ;
\
fi
# for c++ test coverage
.NOTPARALLEL
:
coverage
coverage
:
clean-coverage perform-coverage report-coverage
clean-coverage
:
clean-cpp-coverage
...
...
@@ -105,8 +120,8 @@ report-coverage: report-cpp-coverage
# for static C++ check using cppcheck (when available)
cppcheck
:
cppcheck
-I
./src/lib
-I
./src/bin
--enable
=
all
--suppressions
\
src/cppcheck-suppress.lst
--inline-suppr
\
cppcheck
-I
./src/lib
-I
./src/bin
--enable
=
all
\
--suppressions-list
=
src/cppcheck-suppress.lst
--inline-suppr
\
--quiet
--error-exitcode
=
1
\
--template
'{file}:{line}: check_fail: {message} ({severity},{id})'
\
src
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment