Skip to content

Commit

Permalink
* win32/Makefile.sub (newline.c, miniprelude.c): search from source
Browse files Browse the repository at this point in the history
  directory, not depending on VPATH.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35135 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
  • Loading branch information
nobu committed Mar 26, 2012
1 parent 7a0d81e commit ddc7bcd
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 4 deletions.
3 changes: 3 additions & 0 deletions Makefile.in
Expand Up @@ -148,6 +148,9 @@ INSTALLED_LIST= .installed.list

MKMAIN_CMD = mkmain.sh

NEWLINE_C = newline.c
MINIPRELUDE_C = miniprelude.c

SRC_FILE = $<

MESSAGE_BEGIN = @for line in
Expand Down
8 changes: 4 additions & 4 deletions common.mk
Expand Up @@ -773,9 +773,9 @@ unicode.$(OBJEXT): {$(VPATH)}unicode.c {$(VPATH)}regint.h \
utf_8.$(OBJEXT): {$(VPATH)}utf_8.c {$(VPATH)}regenc.h {$(VPATH)}config.h \
{$(VPATH)}oniguruma.h {$(VPATH)}missing.h

newline.c: $(srcdir)/enc/trans/newline.trans $(srcdir)/tool/transcode-tblgen.rb
$(Q) $(BASERUBY) "$(srcdir)/tool/transcode-tblgen.rb" -vo newline.c $(srcdir)/enc/trans/newline.trans
newline.$(OBJEXT): {$(VPATH)}newline.c {$(VPATH)}defines.h \
$(NEWLINE_C): $(srcdir)/enc/trans/newline.trans $(srcdir)/tool/transcode-tblgen.rb
$(Q) $(BASERUBY) "$(srcdir)/tool/transcode-tblgen.rb" -vo $@ $(srcdir)/enc/trans/newline.trans
newline.$(OBJEXT): $(NEWLINE_C) {$(VPATH)}defines.h \
{$(VPATH)}intern.h {$(VPATH)}missing.h {$(VPATH)}st.h \
{$(VPATH)}transcode_data.h {$(VPATH)}ruby.h {$(VPATH)}config.h {$(VPATH)}subst.h

Expand Down Expand Up @@ -835,7 +835,7 @@ known_errors.inc: $(srcdir)/template/known_errors.inc.tmpl $(srcdir)/defs/known_
$(ECHO) generating $@
$(Q) $(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
$(MINIPRELUDE_C): $(srcdir)/tool/compile_prelude.rb $(srcdir)/prelude.rb
$(ECHO) generating $@
$(Q) $(BASERUBY) -I$(srcdir) $(srcdir)/tool/compile_prelude.rb $(srcdir)/prelude.rb $@

Expand Down
11 changes: 11 additions & 0 deletions win32/Makefile.sub
Expand Up @@ -370,6 +370,17 @@ ruby: $(PROGRAM)
rubyw: $(WPROGRAM)
stub: $(STUBPROGRAM)

!if !exist(newline.c) && exist($(srcdir)/newline.c)
NEWLINE_C = $(srcdir)/newline.c
!else
NEWLINE_C = newline.c
!endif
!if !exist(miniprelude.c) && exist($(srcdir)/miniprelude.c)
MINIPRELUDE_C = $(srcdir)/miniprelude.c
!else
MINIPRELUDE_C = miniprelude.c
!endif

!include $(srcdir)/common.mk

!ifdef SCRIPTPROGRAMS
Expand Down

0 comments on commit ddc7bcd

Please sign in to comment.