Ver Fonte

Remove `clean` before `test` or `check`

The `clean` doesn't appear to serve a purpose. Make already does
dependency tracking, so if files are out of date they will be rebuilt.

The `clean` rule does however cause problems when the test executable
already exists. In that case it will delete outputs, including the test
executable, and then fail. By the time the test executable was deleted,
it was already determined that it was up to date, and so does not get
rebuilt. You end up having to run the command twice, each time seesawing
between deleting outputs or generating outputs and running the tests.
Daniel Stevens há 6 anos atrás
pai
commit
22e5db1402
1 ficheiros alterados com 2 adições e 2 exclusões
  1. 2 2
      Makefile

+ 2 - 2
Makefile

@@ -41,11 +41,11 @@ clean:
 distclean:
 	-$(RM) *.o xmltest libtinyxml2.a
 
-test: clean xmltest
+test: xmltest
 	./xmltest
 
 # Standard GNU target
-check: clean xmltest
+check: xmltest
 	./xmltest
 
 staticlib: libtinyxml2.a