diff options
Diffstat (limited to 'ext')
-rw-r--r-- | ext/extmk.rb | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/ext/extmk.rb b/ext/extmk.rb index 0485568d6b..f7cffa72ec 100644 --- a/ext/extmk.rb +++ b/ext/extmk.rb @@ -73,7 +73,9 @@ def extmake(target) $srcdir = File.join($top_srcdir, "ext", $mdir) unless $ignore if $static || - older("./Makefile", *MTIMES + %W"#{$srcdir}/makefile.rb #{$srcdir}/extconf.rb") + !(t = modified?("./Makefile", MTIMES)) || + %W<#{$srcdir}/makefile.rb #{$srcdir}/extconf.rb + #{$srcdir}/depend #{$srcdir}/MANIFEST>.any? {|f| modified?(f, [t])} then $defs = [] Logging::logfile 'mkmf.log' @@ -244,7 +246,7 @@ if $extlist.size > 0 end src = "void Init_ext() {\n#$extinit}\n" - if older("extinit.c", *MTIMES) || IO.read("extinit.c") != src + if !modified?("extinit.c", MTIMES) || IO.read("extinit.c") != src open("extinit.c", "w") {|f| f.print src} end @@ -268,6 +270,9 @@ rubies = [] } Dir.chdir ".." +if $extlist.size > 0 + rm_f(Config::CONFIG["LIBRUBY_SO"]) +end puts "making #{rubies.join(', ')}" $stdout.flush $mflags.concat(rubies) |