+.PHONY: cscope
+
+
+##
+## Use GNU gcov to find the coverage of the test suite.
+## gcov and gcov-clean are not integrated into the other automake
+## targets because gcov will be used so infrequently, if at all.
+##
+gcov:
+ @echo rebuilding with AM_CLFAGS=--coverage . . .
+ @(make clean && make AM_CFLAGS=--coverage) > /dev/null && make check
+ @for i in `find . -name '*.gcda'`; do \
+ gcov -o `echo $$i | $(SED) 's%\\(.*\\)/%\\1 %'`; \
+ done
+ @for i in `find . -name '*.gcno'`; do \
+ if ! test -f `echo $$i | sed 's%\.gcno%.gcda%'`; then \
+ echo untested: $$i; \
+ fi; \
+ done
+gcov-clean:
+ @find . -name '*.gcno' -o -name '*.gcda' -o -name '*.gcov' | xargs rm
+.PHONY: gcov gcov-clean
+
+
+##
+## Rules to upload the distribution to savannah
+##
+upload: dist
+ @if test -z "$(SAVANNAH_USERNAME)"; then \
+ echo "You need to set SAVANNAH_USERNAME to the your username on savannah.gnu.org." ;\
+ echo "You can set it either in your environment or on the make command line."; \
+ false; \
+ fi
+ @echo "Did you run 'make distcheck' already?"
+ @if test -z "$(SKIP_GPG_SIG)"; then \
+ echo "Creating GPG signature (set SKIP_GPG_SIG to bypass this step)"; \
+ gpg --output $(DIST_ARCHIVES).sig --detatch-sig $(DIST_ARCHIVES); \
+ fi
+ @echo "Setting permissions for savannah.gnu.org"
+ chmod 664 $(DIST_ARCHIVES)
+ if test -f $(DIST_ARCHIVES).sig; then \
+ chmod 664 $(DIST_ARCHIVES).sig; \
+ fi
+ @echo "Uploading to savannah"
+ scp -p $(DIST_ARCHIVES)* $(SAVANNAH_USERNAME)@savannah.gnu.org:/releases/nmh
+.PHONY: upload