[前][次][番号順一覧][スレッド一覧]

ruby-changes:11128

From: nobu <ko1@a...>
Date: Tue, 3 Mar 2009 17:12:09 +0900 (JST)
Subject: [ruby-changes:11128] Ruby:r22728 (ruby_1_8, trunk): * ext/extmk.rb (extmake): removes object files no longer used and

nobu	2009-03-03 17:10:10 +0900 (Tue, 03 Mar 2009)

  New Revision: 22728

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=22728

  Log:
    * ext/extmk.rb (extmake): removes object files no longer used and
      files to be removed by old distclean.

  Modified files:
    branches/ruby_1_8/ChangeLog
    branches/ruby_1_8/ext/extmk.rb
    trunk/ChangeLog
    trunk/ext/extmk.rb

Index: ChangeLog
===================================================================
--- ChangeLog	(revision 22727)
+++ ChangeLog	(revision 22728)
@@ -1,3 +1,8 @@
+Tue Mar  3 17:10:09 2009  Nobuyoshi Nakada  <nobu@r...>
+
+	* ext/extmk.rb (extmake): removes object files no longer used and
+	  files to be removed by old distclean.
+
 Tue Mar  3 16:51:51 2009  NAKAMURA Usaku  <usa@r...>
 
 	* ext/dl/win32/lib/win32/resolv.rb: get rid of warning.
@@ -40,8 +45,6 @@
 
 	* common.mk (main): passes $(MAKE) to mkmain_cmd
 
-	* ext/extmk.rb (extmake): removes object files no longer used.
-
 	* ext/extmk.rb (command_output): uses arguments to invoke make.
 
 Tue Mar  3 01:56:03 2009  Tanaka Akira  <akr@f...>
Index: ext/extmk.rb
===================================================================
--- ext/extmk.rb	(revision 22727)
+++ ext/extmk.rb	(revision 22728)
@@ -80,6 +80,7 @@
   end
   $objs = (m[/^OBJS[ \t]*=[ \t](.*)/, 1] || "").split
   $srcs = (m[/^SRCS[ \t]*=[ \t](.*)/, 1] || "").split
+  $distcleanfiles = (m[/^DISTCLEANFILES[ \t]*=[ \t](.*)/, 1] || "").split
   $LOCAL_LIBS = m[/^LOCAL_LIBS[ \t]*=[ \t]*(.*)/, 1] || ""
   $LIBPATH = Shellwords.shellwords(m[/^libpath[ \t]*=[ \t]*(.*)/, 1] || "") - %w[$(libdir) $(topdir)]
   true
@@ -139,6 +140,7 @@
 	$extconf_h = nil
 	ok &&= extract_makefile(makefile)
 	old_objs = $objs
+	old_cleanfiles = $distcleanfiles
 	conf = ["#{$srcdir}/makefile.rb", "#{$srcdir}/extconf.rb"].find {|f| File.exist?(f)}
 	if (($extconf_h && !File.exist?($extconf_h)) ||
 	    !(t = modified?(makefile, MTIMES)) ||
@@ -179,7 +181,8 @@
       args += ["static"] unless $clean
       $extlist.push [$static, $target, File.basename($target), $preload]
     end
-    FileUtils.rm_f($objs - old_objs)
+    FileUtils.rm_f(old_cleanfiles - $distcleanfiles)
+    FileUtils.rm_f(old_objs - $objs)
     unless system($make, *args)
       $ignore or $continue or return false
     end
Index: ruby_1_8/ext/extmk.rb
===================================================================
--- ruby_1_8/ext/extmk.rb	(revision 22727)
+++ ruby_1_8/ext/extmk.rb	(revision 22728)
@@ -88,6 +88,7 @@
   end
   $objs = (m[/^OBJS[ \t]*=[ \t](.*)/, 1] || "").split
   $srcs = (m[/^SRCS[ \t]*=[ \t](.*)/, 1] || "").split
+  $distcleanfiles = (m[/^DISTCLEANFILES[ \t]*=[ \t](.*)/, 1] || "").split
   $LOCAL_LIBS = m[/^LOCAL_LIBS[ \t]*=[ \t]*(.*)/, 1] || ""
   $LIBPATH = Shellwords.shellwords(m[/^libpath[ \t]*=[ \t]*(.*)/, 1] || "") - %w[$(libdir) $(topdir)]
   true
@@ -147,6 +148,7 @@
 	$extconf_h = nil
 	ok &&= extract_makefile(makefile)
 	old_objs = $objs
+	old_cleanfiles = $distcleanfiles
 	conf = ["#{$srcdir}/makefile.rb", "#{$srcdir}/extconf.rb"].find {|f| File.exist?(f)}
 	if (($extconf_h && !File.exist?($extconf_h)) ||
 	    !(t = modified?(makefile, MTIMES)) ||
@@ -187,7 +189,8 @@
       args += ["static"] unless $clean
       $extlist.push [$static, $target, File.basename($target), $preload]
     end
-    FileUtils.rm_f($objs - old_objs)
+    FileUtils.rm_f(old_cleanfiles - $distcleanfiles)
+    FileUtils.rm_f(old_objs - $objs)
     unless system($make, *args)
       $ignore or $continue or return false
     end
Index: ruby_1_8/ChangeLog
===================================================================
--- ruby_1_8/ChangeLog	(revision 22727)
+++ ruby_1_8/ChangeLog	(revision 22728)
@@ -1,6 +1,7 @@
-Tue Mar  3 16:31:43 2009  Nobuyoshi Nakada  <nobu@r...>
+Tue Mar  3 17:10:09 2009  Nobuyoshi Nakada  <nobu@r...>
 
-	* ext/extmk.rb (extmake): removes object files no longer used.
+	* ext/extmk.rb (extmake): removes object files no longer used and
+	  files to be removed by old distclean.
 
 Tue Mar  3 16:25:43 2009  Nobuyoshi Nakada  <nobu@r...>
 

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]