[前][次][番号順一覧][スレッド一覧]

ruby-changes:54060

From: nobu <ko1@a...>
Date: Sat, 8 Dec 2018 10:49:09 +0900 (JST)
Subject: [ruby-changes:54060] nobu:r66279 (trunk): Use BUILDDIR in ruby-runner.h from config.status

nobu	2018-12-08 10:49:02 +0900 (Sat, 08 Dec 2018)

  New Revision: 66279

  https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=66279

  Log:
    Use BUILDDIR in ruby-runner.h from config.status

  Modified files:
    trunk/.gitignore
    trunk/Makefile.in
    trunk/common.mk
    trunk/ruby-runner.c
Index: common.mk
===================================================================
--- common.mk	(revision 66278)
+++ common.mk	(revision 66279)
@@ -631,7 +631,7 @@ clean-srcs-local:: https://github.com/ruby/ruby/blob/trunk/common.mk#L631
 	$(Q)$(RM) parse.c parse.h lex.c enc/trans/newline.c revision.h
 	$(Q)$(RM) id.c id.h probes.dmyh probes.h
 	$(Q)$(RM) encdb.h transdb.h verconf.h ruby-runner.h
-	$(Q)$(RM) mjit_build_dir.c mjit_config.h rb_mjit_header.h
+	$(Q)$(RM) mjit_config.h rb_mjit_header.h
 	$(Q)$(RM) $(MJIT_MIN_HEADER) $(MJIT_MIN_HEADER:.h=)$(MJIT_HEADER_SUFFIX:%=*).h
 
 realclean-srcs-local:: clean-srcs-local
Index: ruby-runner.c
===================================================================
--- ruby-runner.c	(revision 66278)
+++ ruby-runner.c	(revision 66279)
@@ -9,6 +9,10 @@ https://github.com/ruby/ruby/blob/trunk/ruby-runner.c#L9
 #include "ruby-runner.h"
 #include "ruby/config.h"
 
+#ifdef MAKE_MJIT_BUILD_DIR
+const char MJIT_BUILD_DIR[] = BUILDDIR;
+#else
+
 #define STRINGIZE(expr) STRINGIZE0(expr)
 #define STRINGIZE0(expr) #expr
 
@@ -90,3 +94,5 @@ main(int argc, char **argv) https://github.com/ruby/ruby/blob/trunk/ruby-runner.c#L94
     perror(rubypath);
     return -1;
 }
+
+#endif  /* MAKE_MJIT_BUILD_DIR */
Index: Makefile.in
===================================================================
--- Makefile.in	(revision 66278)
+++ Makefile.in	(revision 66279)
@@ -613,10 +613,6 @@ mjit_config.h: https://github.com/ruby/ruby/blob/trunk/Makefile.in#L613
 	} > $@
 
 yes-test-almost yes-test-all: mjit_build_dir.$(SOEXT)
-mjit_build_dir.$(SOEXT): $(MJIT_MIN_HEADER)
+mjit_build_dir.$(SOEXT): $(MJIT_MIN_HEADER) $(srcdir)/ruby-runner.c ruby-runner.h
 	$(ECHO) making $@
-	$(Q) { \
-	echo 'const char MJIT_BUILD_DIR[] = "'"`$(CHDIR) . && pwd`"'";'; \
-	} > $(@:.$(SOEXT)=.c)
-	$(Q) cat $(@:.$(SOEXT)=.c)
-	$(Q) $(DLDSHARED) $(MJIT_DLDFLAGS) $(ARCH_FLAG) $(CFLAGS) $(CPPFLAGS) $(@:.$(SOEXT)=.c) $(OUTFLAG)$@
+	$(Q) $(DLDSHARED) $(MJIT_DLDFLAGS) $(ARCH_FLAG) $(CFLAGS) $(CPPFLAGS) -DMAKE_MJIT_BUILD_DIR=1 $(OUTFLAG)$@ $(srcdir)/ruby-runner.c
Index: .gitignore
===================================================================
--- .gitignore	(revision 66278)
+++ .gitignore	(revision 66279)
@@ -95,7 +95,6 @@ lcov*.info https://github.com/ruby/ruby/blob/trunk/.gitignore#L95
 /libruby*.*
 /miniprelude.c
 /miniruby
-/mjit_build_dir.c
 /newdate.rb
 /newline.c
 /newver.rb

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]