summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-11-26 03:47:47 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-11-26 03:47:47 +0000
commitb1ad07bd1aefb14fa0a2c6ae38c0a212328f3121 (patch)
treef02798b7aeaceb42b66b6b61313302621b3d4401
parentbf5c84a41dde90497f3f382d6ee378bc978239a8 (diff)
common.mk: simplify for ruby.imp
* common.mk (ruby.imp): extract the first word on the next lines of MJIT_FUNC_EXPORTED, regardless the prefix. duplicate symbols will be removed by `sort -u`. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@65983 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--common.mk4
1 files changed, 2 insertions, 2 deletions
diff --git a/common.mk b/common.mk
index 2ff2de058c..8758eb6ff3 100644
--- a/common.mk
+++ b/common.mk
@@ -347,8 +347,8 @@ ruby.imp: $(COMMONOBJS)
$(Q){ \
$(NM) -Pgp $(COMMONOBJS) | \
awk 'BEGIN{print "#!"}; $$2~/^[BDT]$$/&&$$1!~/^$(SYMBOL_PREFIX)(Init_|InitVM_|ruby_static_id_|.*_threadptr_|rb_ec_)|^\./{print $$1}'; \
- ($(CHDIR) $(srcdir) && for filename in cont.c gc.c thread*c vm*.c; do for linenum in `grep -n -h ^MJIT_FUNC_EXPORTED $${filename} | cut -f 1 -d :`; do sed -n "$${linenum},`expr $${linenum} + 1` p" $${filename}; done; done) | \
- grep -e ^rb_ec_ -e ^rb_threadptr_ | sed 's/^\(rb_[a-zA-Z_0-9]*\).*/$(SYMBOL_PREFIX)\1/'; \
+ ($(CHDIR) $(srcdir) && \
+ exec sed -n '/^MJIT_FUNC_EXPORTED/!d;N;s/.*\n\(rb_[a-zA-Z_0-9]*\).*/$(SYMBOL_PREFIX)\1/p' cont.c gc.c thread*c vm*.c) \
} | \
sort -u -o $@