From 7d7f1ef157f9b7ab4d5c661fd155e2160efd4419 Mon Sep 17 00:00:00 2001 From: nobu Date: Sun, 17 Aug 2003 02:32:07 +0000 Subject: [PATCH] * ext/extmk.rb (extmake): should not force to remake Makefile when installation and so on. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4398 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 5 +++++ ext/extmk.rb | 8 ++++---- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index 22be2e221d..668b984da8 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Sun Aug 17 11:32:04 2003 Nobuyoshi Nakada + + * ext/extmk.rb (extmake): should not force to remake Makefile when + installation and so on. + Sat Aug 16 23:58:18 2003 Nobuyoshi Nakada * marshal.c (w_symbol, w_object): get rid of warnings. diff --git a/ext/extmk.rb b/ext/extmk.rb index bb50579c92..5f99c85ea9 100644 --- a/ext/extmk.rb +++ b/ext/extmk.rb @@ -25,8 +25,6 @@ srcdir = Config::CONFIG["srcdir"] $:.replace [srcdir, srcdir+"/lib", "."] require 'mkmf' -require 'ftools' -require 'shellwords' require 'getopts' $topdir = File.expand_path(".") @@ -55,7 +53,7 @@ def extmake(target) begin dir = Dir.pwd - File.mkpath target unless File.directory?(target) + FileUtils.mkpath target unless File.directory?(target) Dir.chdir target $target = target $mdir = target @@ -91,6 +89,8 @@ def extmake(target) else true end + else + File.exist?(makefile) end or open(makefile, "w") do |f| f.print dummy_makefile($srcdir) return true @@ -214,7 +214,7 @@ for dir in ["ext", File::join($top_srcdir, "ext")] end end -File::makedirs('ext') +FileUtils::makedirs('ext') Dir::chdir('ext') ext_prefix = "#{$top_srcdir}/ext"