From 6d55a704454c197b725fa91acb061841aa6805df Mon Sep 17 00:00:00 2001 From: shyouhei Date: Sat, 21 Feb 2009 15:50:27 +0000 Subject: merge revision(s) 21297: * ext/extmk.rb (extmake): does not use both of makefile.rb and extconf.rb at the same time. * lib/mkmf.rb (DLLIB): depends on Makefile. [ruby-core:21096] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8_7@22484 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ext/extmk.rb | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'ext') diff --git a/ext/extmk.rb b/ext/extmk.rb index 64746552c1..2527645ad8 100644 --- a/ext/extmk.rb +++ b/ext/extmk.rb @@ -154,18 +154,17 @@ def extmake(target) begin $extconf_h = nil ok &&= extract_makefile(makefile) + conf = ["#{$srcdir}/makefile.rb", "#{$srcdir}/extconf.rb"].find {|f| File.exist?(f)} if (($extconf_h && !File.exist?($extconf_h)) || !(t = modified?(makefile, MTIMES)) || - ["#{$srcdir}/makefile.rb", "#{$srcdir}/extconf.rb", "#{$srcdir}/depend"].any? {|f| modified?(f, [t])}) + [conf, "#{$srcdir}/depend"].any? {|f| modified?(f, [t])}) then ok = false init_mkmf Logging::logfile 'mkmf.log' rm_f makefile - if File.exist?($0 = "#{$srcdir}/makefile.rb") - load $0 - elsif File.exist?($0 = "#{$srcdir}/extconf.rb") - load $0 + if conf + load $0 = conf else create_makefile(target) end -- cgit v1.2.3