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

ruby-changes:27200

From: nobu <ko1@a...>
Date: Fri, 15 Feb 2013 18:25:00 +0900 (JST)
Subject: [ruby-changes:27200] nobu:r39252 (trunk): mkmf.rb: fail if cross compiling

nobu	2013-02-15 18:24:50 +0900 (Fri, 15 Feb 2013)

  New Revision: 39252

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

  Log:
    mkmf.rb: fail if cross compiling
    
    * lib/mkmf.rb (MakeMakefile#try_run): bail out explicitly if cross
      compiling, because it cannot work of course.

  Modified files:
    trunk/ChangeLog
    trunk/lib/mkmf.rb

Index: ChangeLog
===================================================================
--- ChangeLog	(revision 39251)
+++ ChangeLog	(revision 39252)
@@ -1,3 +1,8 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1
+Fri Feb 15 18:24:48 2013  Nobuyoshi Nakada  <nobu@r...>
+
+	* lib/mkmf.rb (MakeMakefile#try_run): bail out explicitly if cross
+	  compiling, because it cannot work of course.
+
 Fri Feb 15 12:34:58 2013  Tanaka Akira  <akr@f...>
 
 	* ext/socket/extconf.rb: test struct sockaddr_storage directly.
Index: lib/mkmf.rb
===================================================================
--- lib/mkmf.rb	(revision 39251)
+++ lib/mkmf.rb	(revision 39252)
@@ -811,6 +811,7 @@ SRC https://github.com/ruby/ruby/blob/trunk/lib/mkmf.rb#L811
   # Returns true when the executable exits successfully, false when it fails,
   # or nil when preprocessing, compilation or link fails.
   def try_run(src, opt = "", &b)
+    raise "cannot run test program while cross compiling" if CROSS_COMPILING
     if try_link0(src, opt, &b)
       xsystem("./conftest")
     else

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

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