build: only move tar archive to target name on success

Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
This commit is contained in:
Kevin Shanahan 2013-04-24 12:22:06 +09:30
parent 45fa5a6e39
commit 0ad7bac1d3
1 changed files with 3 additions and 1 deletions

View File

@ -662,7 +662,9 @@ $(DIST_DIR)/tyrutils-$(TYR_VERSION_NUM)-win32.zip: $(DIST_FILES_WIN32)
quiet_cmd_git_archive = ' GIT-ARCV $@'
cmd_git_archive = \
git archive --format=tar --prefix=tyrutils-$(TYR_VERSION_NUM)/ HEAD > $@
git archive --format=tar --prefix=tyrutils-$(TYR_VERSION_NUM)/ HEAD \
> $(@D)/.$(@F).tmp && \
mv $(@D)/.$(@F).tmp $@
define do_git_archive
$(do_mkdir)