Code

t/coverage.sh: Fall-back to lcov without --no-external.
authorSebastian Harl <sh@tokkee.org>
Sun, 23 Feb 2014 04:14:26 +0000 (20:14 -0800)
committerSebastian Harl <sh@tokkee.org>
Sun, 23 Feb 2014 04:14:26 +0000 (20:14 -0800)
Old versions of lcov don't support that flag. Simply try to fall back in case
the first run fails.

t/coverage.sh

index 5dabb13955277df4f73627a72b14eb87ed1b1455..29f8c99a7ad7b7f914dea601aa93ccfde413cda4 100755 (executable)
@@ -46,8 +46,11 @@ make
 
 lcov --base-directory src --directory src --zerocount
 make test
+# old versions of lcov don't support --no-external
 lcov --base-directory src --directory src --no-external \
-       --capture -o sysdb_coverage.info
+       --capture -o sysdb_coverage.info \
+       || lcov --base-directory src --directory src \
+               --capture -o sysdb_coverage.info
 
 V=$( ./version-gen.sh )
 genhtml -o "$srcdir"/t/coverage \