diff --git a/ChangeLog b/ChangeLog index 9e57d8500e..1c0b5db8c7 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +Sat Jan 3 03:00:42 2009 NAKAMURA Usaku + + * common.mk, Makefile.in, win32/Makefile.sub ($(INSNS), node_name.inc, + known_errors.inc, miniprelude.c, newline.c): move rules from common.mk + to {Makefile.in,win32/Makefile.sub) for nmake. + [ruby-core:20993] + Fri Jan 2 23:51:41 2009 Yusuke Endoh * test/ruby/test_sleep.rb (test_sleep_5sec): stop gc. diff --git a/Makefile.in b/Makefile.in index 8b9a12af56..d4ab5ad321 100644 --- a/Makefile.in +++ b/Makefile.in @@ -269,3 +269,19 @@ update-rubyspec: test-rubyspec: @if [ ! -d $(srcdir)/spec/rubyspec ]; then echo No rubyspec here. make update-rubyspec first.; exit 1; fi $(RUNRUBY) $(srcdir)/spec/mspec/bin/mspec -B $(srcdir)/spec/default.mspec $(MSPECOPT) + +$(INSNS): + @$(RM) $(PROGRAM) + $(BASERUBY) -Ks $(srcdir)/tool/insns2vm.rb $(INSNS2VMOPT) $@ + +node_name.inc: + $(BASERUBY) -n $(srcdir)/tool/node_name.rb $? > $@ + +known_errors.inc: + $(BASERUBY) $(srcdir)/tool/generic_erb.rb -c -o $@ $(srcdir)/template/known_errors.inc.tmpl $(srcdir)/defs/known_errors.def + +miniprelude.c: + $(BASERUBY) -I$(srcdir) $(srcdir)/tool/compile_prelude.rb $(srcdir)/prelude.rb $@ + +newline.c: + $(BASERUBY) "$(srcdir)/tool/transcode-tblgen.rb" -vo newline.c $(srcdir)/enc/trans/newline.trans diff --git a/common.mk b/common.mk index 5cb4f1610b..e10a9f1798 100644 --- a/common.mk +++ b/common.mk @@ -621,8 +621,6 @@ INSNS = opt_sc.inc optinsn.inc optunifs.inc insns.inc insns_info.inc \ INSNS2VMOPT = --srcdir="$(srcdir)" $(INSNS): $(srcdir)/insns.def {$(VPATH)}vm_opts.h $(srcdir)/defs/opt_operand.def $(srcdir)/defs/opt_insn_unif.def - @$(RM) $(PROGRAM) - $(BASERUBY) -Ks $(srcdir)/tool/insns2vm.rb $(INSNS2VMOPT) $@ minsns.inc: $(srcdir)/template/minsns.inc.tmpl @@ -650,7 +648,6 @@ incs: $(INSNS) {$(VPATH)}node_name.inc {$(VPATH)}encdb.h {$(VPATH)}transdb.h {$( insns: $(INSNS) node_name.inc: {$(VPATH)}node.h - $(BASERUBY) -n $(srcdir)/tool/node_name.rb $? > $@ encdb.h: $(PREP) $(MINIRUBY) $(srcdir)/enc/make_encdb.rb $@.new $(srcdir)/enc enc @@ -665,10 +662,8 @@ transdb.h: $(PREP) srcs-enc # $(srcdir)/template/id.h.tmpl --vpath=$(VPATH) parse.h known_errors.inc: $(srcdir)/template/known_errors.inc.tmpl $(srcdir)/defs/known_errors.def - $(BASERUBY) $(srcdir)/tool/generic_erb.rb -c -o $@ $(srcdir)/template/known_errors.inc.tmpl $(srcdir)/defs/known_errors.def miniprelude.c: $(srcdir)/tool/compile_prelude.rb $(srcdir)/prelude.rb - $(BASERUBY) -I$(srcdir) $(srcdir)/tool/compile_prelude.rb $(srcdir)/prelude.rb $@ prelude.c: $(srcdir)/tool/compile_prelude.rb $(RBCONFIG) $(PRELUDE_SCRIPTS) $(PREP) $(COMPILE_PRELUDE) $(PRELUDE_SCRIPTS) $@ @@ -676,9 +671,6 @@ prelude.c: $(srcdir)/tool/compile_prelude.rb $(RBCONFIG) $(PRELUDE_SCRIPTS) $(PR golf_prelude.c: $(srcdir)/tool/compile_prelude.rb $(RBCONFIG) $(srcdir)/prelude.rb $(srcdir)/golf_prelude.rb $(PREP) $(COMPILE_PRELUDE) $(srcdir)/golf_prelude.rb $@ -newline.c: - $(BASERUBY) "$(srcdir)/tool/transcode-tblgen.rb" -vo newline.c $(srcdir)/enc/trans/newline.trans - prereq: incs srcs preludes preludes: {$(VPATH)}miniprelude.c diff --git a/win32/Makefile.sub b/win32/Makefile.sub index 0586c1ba36..d2efe4c163 100644 --- a/win32/Makefile.sub +++ b/win32/Makefile.sub @@ -757,3 +757,39 @@ dir.$(OBJEXT) win32.$(OBJEXT): {$(srcdir)}win32/dir.h ext/extinit.obj: ext/extinit.c $(SETUP) $(CC) $(CFLAGS) $(XCFLAGS) $(CPPFLAGS) $(COUTFLAG)$@ -c ext/extinit.c + +$(INSNS): + @if exist $(srcdir:/=\)\insns.inc ( \ + @for %I in ($(INSNS)) do @copy $(srcdir:/=\)\%~nxI %I \ + ) else ( \ + @$(RM) $(PROGRAM) \ + $(BASERUBY) -Ks $(srcdir)/tool/insns2vm.rb $(INSNS2VMOPT) $@ \ + ) + +node_name.inc: + @if exist $(srcdir:/=\)\$(@F) ( \ + copy $(srcdir:/=\)\$(@F) $@ \ + ) else ( \ + $(BASERUBY) -n $(srcdir)/tool/node_name.rb $? > $@ \ + ) + +known_errors.inc: + @if exist $(srcdir:/=\)\$(@F) ( \ + copy $(srcdir:/=\)\$(@F) $@ \ + ) else ( \ + $(BASERUBY) $(srcdir)/tool/generic_erb.rb -c -o $@ $(srcdir)/template/known_errors.inc.tmpl $(srcdir)/defs/known_errors.def \ + ) + +miniprelude.c: + @if exist $(srcdir:/=\)\$(@F) ( \ + copy $(srcdir:/=\)\$(@F) $@ \ + ) else ( \ + $(BASERUBY) -I$(srcdir) $(srcdir)/tool/compile_prelude.rb $(srcdir)/prelude.rb $@ \ + ) + +newline.c: + @if exist $(srcdir:/=\)\$(@F) ( \ + copy $(srcdir:/=\)\$(@F) $@ \ + ) else ( \ + $(BASERUBY) "$(srcdir)/tool/transcode-tblgen.rb" -vo newline.c $(srcdir)/enc/trans/newline.trans \ + )