Fix the update target and remove duplicate file updates
[openssl.git] / test / Makefile
index 956694543db657f7e2819726c73f84fa9c460ab8..3fe5f193d910134fe5ebdc1d5db0d9f2ac7e166d 100644 (file)
@@ -321,12 +321,13 @@ test_constant_time: $(CONSTTIMETEST)$(EXE_EXT)
 lint:
        lint -DLINT $(INCLUDES) $(SRC)>fluff
 
-depend:
-       @if [ -z "$(THIS)" ]; then \
-           $(MAKE) -f $(TOP)/Makefile reflect THIS=$@; \
-       else \
-           $(MAKEDEPEND) -- $(CFLAG) $(INCLUDES) $(DEPFLAG) -- $(PROGS) $(SRC); \
-       fi
+update: local_depend
+       @if [ -z "$(THIS)" ]; then $(MAKE) -f $(TOP)/Makefile reflect THIS=$@; fi
+
+depend: local_depend
+       @if [ -z "$(THIS)" ]; then $(MAKE) -f $(TOP)/Makefile reflect THIS=$@; fi
+local_depend:
+       @[ -z "$(THIS)" ] || $(MAKEDEPEND) -- $(CFLAG) $(INCLUDES) $(DEPFLAG) -- $(PROGS) $(SRC)
 
 dclean:
        $(PERL) -pe 'if (/^# DO NOT DELETE THIS LINE/) {print; exit(0);}' $(MAKEFILE) >Makefile.new