1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* common.mk (ext/ripper/ripper.c): pass build directory as VPATH.

* ext/ripper/depend (.y.c): use VPATH for y.tab.c.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48493 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
naruse 2014-11-19 09:00:33 +00:00
parent a494ed4113
commit 926b9e05f1
3 changed files with 10 additions and 3 deletions

View file

@ -1,3 +1,9 @@
Wed Nov 19 17:59:25 2014 NARUSE, Yui <naruse@ruby-lang.org>
* common.mk (ext/ripper/ripper.c): pass build directory as VPATH.
* ext/ripper/depend (.y.c): use VPATH for y.tab.c.
Wed Nov 19 10:07:57 2014 Nobuyoshi Nakada <nobu@ruby-lang.org>
* template/prelude.c.tmpl (Prelude#translate): strip VPATH prefix

View file

@ -807,8 +807,9 @@ $(REVISION_H): $(srcdir)/version.h $(srcdir)/ChangeLog $(srcdir)/tool/file2lastr
$(srcdir)/ext/ripper/ripper.c: parse.y id.h
$(ECHO) generating $@
$(Q) $(CHDIR) $(@D) && $(exec) $(MAKE) -f depend $(MFLAGS) \
Q=$(Q) ECHO=$(ECHO) top_srcdir=../.. srcdir=. VPATH=../.. RUBY="$(BASERUBY)" PATH_SEPARATOR="$(PATH_SEPARATOR)"
$(Q) vpath=`pwd` && $(CHDIR) $(@D) && $(exec) $(MAKE) -f depend $(MFLAGS) \
Q=$(Q) ECHO=$(ECHO) top_srcdir=../.. srcdir=. VPATH=$(vpath) \
RUBY="$(BASERUBY)" PATH_SEPARATOR="$(PATH_SEPARATOR)"
$(srcdir)/ext/json/parser/parser.c: $(srcdir)/ext/json/parser/parser.rl
$(ECHO) generating $@

View file

@ -12,7 +12,7 @@ ripper.o: ripper.c
.y.c:
$(ECHO) compiling compiler $<
$(Q) $(BISON) -t -v -oy.tab.c $<
$(Q) sed -f $(top_srcdir)/tool/ytab.sed -e "/^#/s!y\.tab\.c!$@!" y.tab.c > $@
$(Q) sed -f $(top_srcdir)/tool/ytab.sed -e "/^#/s!y\.tab\.c!$@!" $(VPATH)/y.tab.c > $@
@$(RM) y.tab.c
all: check