Makefile 466 B

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