Advertisement
Guest User

Untitled

a guest
Dec 18th, 2014
137
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.96 KB | None | 0 0
  1. --- a/ext/readline/extconf.rb
  2. +++ b/ext/readline/extconf.rb
  3. @@ -19,6 +19,10 @@ def readline.have_func(func)
  4. return super(func, headers)
  5. end
  6.  
  7. +def readline.have_type(type)
  8. + return super(type, headers)
  9. +end
  10. +
  11. dir_config('curses')
  12. dir_config('ncurses')
  13. dir_config('termcap')
  14. @@ -93,4 +97,7 @@ readline.have_func("remove_history")
  15. readline.have_func("clear_history")
  16. readline.have_func("rl_redisplay")
  17. readline.have_func("rl_insert_text")
  18. +unless readline.have_type("rl_hook_func_t")
  19. + $DEFS << "-Drl_hook_func_t=Function"
  20. +end
  21. create_makefile("readline")
  22. --- a/ext/readline/readline.c
  23. +++ b/ext/readline/readline.c
  24. @@ -1883,7 +1883,7 @@ Init_readline()
  25.  
  26. rl_attempted_completion_function = readline_attempted_completion_function;
  27. #if defined(HAVE_RL_PRE_INPUT_HOOK)
  28. - rl_pre_input_hook = (Function *)readline_pre_input_hook;
  29. + rl_pre_input_hook = (rl_hook_func_t *)readline_pre_input_hook;
  30. #endif
  31. #ifdef HAVE_RL_CATCH_SIGNALS
  32. rl_catch_signals = 0;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement