Skip to content

Commit 8b46c20

Browse files
committed
Split RBCONFIG recipe
And make `ifchange` a pipeline; it works even on Windows now.
1 parent ad0ac0e commit 8b46c20

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

common.mk

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -938,19 +938,23 @@ rbconfig.rb: $(RBCONFIG)
938938

939939
$(HAVE_BASERUBY:no=)$(RBCONFIG)$(HAVE_BASERUBY:no=): $(PREP)
940940
$(RBCONFIG): $(tooldir)/mkconfig.rb config.status $(srcdir)/version.h $(srcdir)/common.mk
941+
$(RBCONFIG): unicode-version
942+
943+
unicode-version:
941944
$(Q)$(BOOTSTRAPRUBY) -n \
942945
-e 'BEGIN{version=ARGV.shift;mis=ARGV.dup}' \
943946
-e 'END{abort "UNICODE version mismatch: #{mis}" unless mis.empty?}' \
944947
-e '(mis.delete(ARGF.path); ARGF.close) if /ONIG_UNICODE_VERSION_STRING +"#{Regexp.quote(version)}"/o' \
945948
$(UNICODE_VERSION) $(UNICODE_DATA_HEADERS)
949+
950+
$(RBCONFIG):
946951
$(Q)$(BOOTSTRAPRUBY) $(tooldir)/mkconfig.rb \
947952
-arch=$(arch) -version=$(RUBY_PROGRAM_VERSION) \
948953
-install_name=$(RUBY_INSTALL_NAME) \
949954
-so_name=$(RUBY_SO_NAME) \
950955
-unicode_version=$(UNICODE_VERSION) \
951956
-unicode_emoji_version=$(UNICODE_EMOJI_VERSION) \
952-
> rbconfig.tmp
953-
$(IFCHANGE) "--timestamp=$@" rbconfig.rb rbconfig.tmp
957+
| $(IFCHANGE) "--timestamp=$@" rbconfig.rb -
954958

955959
test-rubyspec: test-spec
956960
yes-test-rubyspec: yes-test-spec

0 commit comments

Comments
 (0)