cake
/
p7utils
Archived
1
0
Fork 0

Corrected 'Transfer complete' bug, added clean-<bin> and re-<bin> targets

This commit is contained in:
Thomas Touhey 2016-12-27 15:03:00 +01:00
parent 45558c976b
commit 5716c56295
2 changed files with 11 additions and 4 deletions

View File

@ -140,13 +140,19 @@ $(foreach obj,$(SRC_$(bin)),\
$(eval $(call make-binaryobj-rule,$(bin),$(obj)))))
# Make a binary
define make-binary-rule
define make-binary-rules
$1$(if $(FOR_WINDOWS),.exe): $(SRC_$1:%=$(OBJDIR)/$1/%.o) | $(OBJDIR)/$1
$(call bcmd,ld,$$@,$(LD) -o $$@ $$^ $(LDFLAGS))
all-$1: $1$(if $(FOR_WINDOWS),.exe)
clean-$1:
$(call rmsg,Removing $1 and its objects directory.)
$(call qcmd,$(RM) -r $(OBJDIR)/$1)
$(call qcmd,$(RM) $1$(if $(FOR_WINDOWS),.exe))
re-$1: clean-$1 all-$1
endef
$(foreach bin,$(BINARIES),\
$(eval $(call make-binary-rule,$(bin))))
$(eval $(call make-binary-rules,$(bin))))
# Remove object files.
mostlyclean-bins:
@ -182,7 +188,7 @@ $(eval $(call make-installbinary-rule,$(bin))))
$(BINARIES) $(BINARIES:%=%.exe)))
.PHONY: all-bins mostlyclean-bins mclean-bins clean-bins re-bins
.PHONY: $(BINARIES:%=all-%) $(BINARIES:%=install-%)
.PHONY: $(foreach b,$(BINARIES),all-$(b) clean-$(b) re-$(b) install-$(b))
.PHONY: install-bins uninstall-bins
#******************************************************************************#
# Documentation-related #

View File

@ -266,7 +266,8 @@ int main(int ac, char **av)
return (1);
}
puts("\b\b\b\b\b\bTransfer complete.");
if (sendfile_display_initialized)
puts("\b\b\b\b\b\bTransfer complete.");
if (args.local) fclose(args.local);
/* terminate communication and de-initialize libp7 */