ci: add generation of HTML coverage report using lcov

Copied from ndn-cxx

Change-Id: Ie8c08a570afe67c9eb232b37ad0038566ad49572
diff --git a/.jenkins.d/30-coverage.sh b/.jenkins.d/30-coverage.sh
index b00354c..0a83447 100755
--- a/.jenkins.d/30-coverage.sh
+++ b/.jenkins.d/30-coverage.sh
@@ -12,4 +12,25 @@
           --exclude="$PWD/(tests|websocketpp)" \
           --root=. \
           --xml
+
+    # Generate also a detailed HTML output, but using lcov (better results)
+    lcov --quiet \
+         --capture \
+         --directory . \
+         --no-external \
+         --rc lcov_branch_coverage=1 \
+         --output-file build/coverage-with-tests.info
+
+    lcov --quiet \
+         --remove build/coverage-with-tests.info "$PWD/tests/*" \
+         --rc lcov_branch_coverage=1 \
+         --output-file build/coverage.info
+
+    genhtml --branch-coverage \
+            --demangle-cpp \
+            --frames \
+            --legend \
+            --output-directory build/coverage \
+            --title "NFD unit tests" \
+            build/coverage.info
 fi