1all: 2 scons 3 4clean: 5 scons -c 6 7coverage: 8 rm -rf build coverage 9 10 # LCOV does not like the newer gcov format 11 scons CC=gcc-4.6 CXX=gcc-4.6 12 13 # Collect the data 14 mkdir build/coverage 15 lcov --base-directory . --directory build/ --gcov-tool gcov-4.6 -c -o build/coverage/nanopb.info 16 17 # Remove the test code from results 18 lcov -r build/coverage/nanopb.info '*tests*' -o build/coverage/nanopb.info 19 20 # Generate HTML 21 genhtml -o build/coverage build/coverage/nanopb.info 22