add a way to get code coverage
BUG=
R=borenet@google.com
Review URL: https://codereview.chromium.org/23523055
git-svn-id: http://skia.googlecode.com/svn/trunk@11261 2bbb7eff-a529-9590-31e7-b0007b416f81
diff --git a/tools/gcov_shim b/tools/gcov_shim
new file mode 100755
index 0000000..1bac3b7
--- /dev/null
+++ b/tools/gcov_shim
@@ -0,0 +1,15 @@
+#!/bin/bash
+
+# Running gcov with -a (--all-blocks) will hang on some files. lcov uses -a.
+# This shim strips out that flag (a minor feature) so we can run gcov.
+
+CMD="gcov"
+
+while (( "$#" )); do
+ if [[ "$1" != "-a" && "$1" != "-all-blocks" && "$1" != "--all-blocks" ]]; then
+ CMD="$CMD $1"
+ fi
+ shift
+done
+
+$CMD