summaryrefslogtreecommitdiff
path: root/ext/-test-
diff options
context:
space:
mode:
authorNobuyoshi Nakada <nobu@ruby-lang.org>2019-09-19 22:09:43 +0900
committerNobuyoshi Nakada <nobu@ruby-lang.org>2019-09-19 22:09:43 +0900
commite0c56b45a41f052223e23d222ca49c7e0225923e (patch)
treeb14e034631ea5bac3fc8c47bcfb3784b1ca1cb4b /ext/-test-
parenta3daf8e49a36dc5501b020a882d611676a6ad264 (diff)
Moved unmatch arity check to depend file
To substitute suffixes and VPATH for nmake.
Diffstat (limited to 'ext/-test-')
-rw-r--r--ext/-test-/cxxanyargs/depend8
-rw-r--r--ext/-test-/cxxanyargs/extconf.rb13
2 files changed, 9 insertions, 12 deletions
diff --git a/ext/-test-/cxxanyargs/depend b/ext/-test-/cxxanyargs/depend
index 61649e1199..a68afb82d7 100644
--- a/ext/-test-/cxxanyargs/depend
+++ b/ext/-test-/cxxanyargs/depend
@@ -1,3 +1,11 @@
+$(DLLIB) $(STATIC_LIB): failure.failed
+
+failure.failed: failure.cpp cxxanyargs.o
+ $(Q)$(RUBY) -rfileutils \\
+ -e "err = IO.popen(%[$(MAKE) failure.o], err:[:child, :out], &:read)" \\
+ -e "abort err unless /rb_define_method/ =~ err" \\
+ -e "FileUtils.touch(*ARGV)" $@
+
# AUTOGENERATED DEPENDENCIES START
cxxanyargs.o: $(RUBY_EXTCONF_H)
cxxanyargs.o: $(arch_hdrdir)/ruby/config.h
diff --git a/ext/-test-/cxxanyargs/extconf.rb b/ext/-test-/cxxanyargs/extconf.rb
index 90ab85608a..b3f45477ad 100644
--- a/ext/-test-/cxxanyargs/extconf.rb
+++ b/ext/-test-/cxxanyargs/extconf.rb
@@ -24,16 +24,5 @@ end
if ok
$srcs = %w[cxxanyargs.cpp]
$cleanfiles << "failure.failed"
- create_makefile("-test-/cxxanyargs") do |mk|
- mk << <<MK
-
-cxxanyargs.#$OBJEXT: failure.failed
-
-failure.failed: failure.cpp
-\t$(Q)$(RUBY) -rfileutils \\
-\t -e "err = IO.popen(%[$(MAKE) failure.#$OBJEXT], err:[:child, :out], &:read)" \\
-\t -e "abort err unless /rb_define_method/ =~ err" \\
-\t -e "FileUtils.touch(*ARGV)" $@
-MK
- end
+ create_makefile("-test-/cxxanyargs")
end