ruby-changes:50239
From: k0kubun <ko1@a...>
Date: Sun, 11 Feb 2018 14:29:20 +0900 (JST)
Subject: [ruby-changes:50239] k0kubun:r62357 (trunk): common.mk: add comments about r62355 [ci skip]
k0kubun 2018-02-11 14:29:13 +0900 (Sun, 11 Feb 2018) New Revision: 62357 https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=62357 Log: common.mk: add comments about r62355 [ci skip] transform_mjit_header.rb: ditto Modified files: trunk/common.mk trunk/tool/transform_mjit_header.rb Index: tool/transform_mjit_header.rb =================================================================== --- tool/transform_mjit_header.rb (revision 62356) +++ tool/transform_mjit_header.rb (revision 62357) @@ -109,6 +109,7 @@ module MJITHeader https://github.com/ruby/ruby/blob/trunk/tool/transform_mjit_header.rb#L109 end # -dD outputs those macros, and it produces redefinition warnings or errors + # This assumes common.mk passes `-DMJIT_HEADER` first when it creates rb_mjit_header.h. def self.remove_predefined_macros!(code) code.sub!(/\A(#define [^\n]+|\n)*(#define MJIT_HEADER 1\n)/, '\2') end Index: common.mk =================================================================== --- common.mk (revision 62356) +++ common.mk (revision 62357) @@ -211,6 +211,8 @@ mjit-headers: $(TIMESTAMPDIR)/$(MJIT_HEA https://github.com/ruby/ruby/blob/trunk/common.mk#L211 mjit.$(OBJEXT): mjit_config.h mjit_config.h: Makefile +# Other `-Dxxx`s preceding `-DMJIT_HEADER` will be removed in transform_mjit_header.rb. +# So `-DMJIT_HEADER` should be passed first when rb_mjit_header.h is generated. $(TIMESTAMPDIR)/$(MJIT_HEADER:.h=)$(MJIT_HEADER_SUFFIX).time: probes.h vm.$(OBJEXT) $(ECHO) building $(@F:.time=.h) $(Q) $(CPP) -DMJIT_HEADER $(MJIT_HEADER_FLAGS) $(CFLAGS) $(XCFLAGS) $(CPPFLAGS) $(srcdir)/vm.c $(CPPOUTFLAG)$(@F:.time=.h).new -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/