From cca5104f571eaabf53233c3b89194d4bb16e34f6 Mon Sep 17 00:00:00 2001 From: nobu Date: Thu, 26 Jun 2008 15:34:56 +0000 Subject: * common.mk (revision.h): split the temporary file. [ruby-core:17407] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@17590 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 4 ++++ common.mk | 10 ++++++---- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index 8ab825e7f7..2f49b65c13 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +Fri Jun 27 00:34:50 2008 Nobuyoshi Nakada + + * common.mk (revision.h): split the temporary file. [ruby-core:17407] + Fri Jun 27 00:00:14 2008 Nobuyoshi Nakada * ruby.c (set_arg0, ruby_prog_init): freeze $0. a patch from Keita diff --git a/common.mk b/common.mk index b7899e2b76..93c0c78f47 100644 --- a/common.mk +++ b/common.mk @@ -471,11 +471,13 @@ version.$(OBJEXT): {$(VPATH)}version.c {$(VPATH)}ruby.h config.h \ dist: $(PROGRAM) $(RUNRUBY) $(srcdir)/distruby.rb -{$(VPATH)}revision.h: revision.h.tmp - @if [ -f $(srcdir)/revision.h ] && { [ ! -s $? ] || cmp $(srcdir)/revision.h $? >/dev/null; }; then \ - $(RM) $?; \ +{$(VPATH)}revision.h: + @$(MAKE) revision.h.tmp + @if [ -f $(srcdir)/revision.h ] && \ + { [ ! -s revision.h.tmp ] || cmp $(srcdir)/revision.h revision.h.tmp >/dev/null; }; then \ + $(RM) revision.h.tmp; \ else \ - mv -f $? $(srcdir)/revision.h; \ + mv -f revision.h.tmp $(srcdir)/revision.h; \ fi revision.h.tmp: $(REVISION_FORCE) -- cgit v1.2.3