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

ruby-changes:33161

From: nobu <ko1@a...>
Date: Sun, 2 Mar 2014 11:13:47 +0900 (JST)
Subject: [ruby-changes:33161] nobu:r45240 (trunk): extconf.rb: rl_hook_func_t for old readline

nobu	2014-03-02 11:13:41 +0900 (Sun, 02 Mar 2014)

  New Revision: 45240

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

  Log:
    extconf.rb: rl_hook_func_t for old readline
    
    * ext/readline/extconf.rb (rl_hook_func_t): define as Function for
      very old readline versions.  [ruby-core:61209] [Bug #9578]

  Modified files:
    trunk/ChangeLog
    trunk/ext/readline/extconf.rb
Index: ChangeLog
===================================================================
--- ChangeLog	(revision 45239)
+++ ChangeLog	(revision 45240)
@@ -1,3 +1,8 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1
+Sun Mar  2 11:13:30 2014  Nobuyoshi Nakada  <nobu@r...>
+
+	* ext/readline/extconf.rb (rl_hook_func_t): define as Function for
+	  very old readline versions.  [ruby-core:61209] [Bug #9578]
+
 Sun Mar  2 10:56:12 2014  Zachary Scott  <e@z...>
 
 	* README.EXT: [DOC] Remove needless char
Index: ext/readline/extconf.rb
===================================================================
--- ext/readline/extconf.rb	(revision 45239)
+++ ext/readline/extconf.rb	(revision 45240)
@@ -19,6 +19,10 @@ def readline.have_func(func) https://github.com/ruby/ruby/blob/trunk/ext/readline/extconf.rb#L19
   return super(func, headers)
 end
 
+def readline.have_type(type)
+  return super(type, headers)
+end
+
 dir_config('curses')
 dir_config('ncurses')
 dir_config('termcap')
@@ -94,4 +98,8 @@ readline.have_func("clear_history") https://github.com/ruby/ruby/blob/trunk/ext/readline/extconf.rb#L98
 readline.have_func("rl_redisplay")
 readline.have_func("rl_insert_text")
 readline.have_func("rl_delete_text")
+unless readline.have_type("rl_hook_func_t")
+  $DEFS << "-Drl_hook_func_t=Function"
+end
+
 create_makefile("readline")

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

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