[R] How do I compile with readline?

Peter Dalgaard BSA p.dalgaard at biostat.ku.dk
Wed Jan 13 11:26:38 CET 1999

Ulf Mehlig <umehlig at uni-bremen.de> writes:

> "John S. Walker" <jsw9c at avery.med.virginia.edu> wrote:
>  > I'm trying to compile my version of R with the readline library and
>  > it doesn't seem to work.  I've tried --enable-readline and while
>  > the readline_history options appear to be set in the config.cache
>  > file activated I don't seem to be linking agains the readline
>  > library (it is in it's usual place).  I'm not getting any error
>  > messages.  Any suggestions?
> I once had this problem on my computer -- the problem was simply that
> I didn't have the readline development libraries an my machine (that
> might be a separate package in one or the other Linux distribution).
> Don't know, but maybe it's just that ...

Yes. Trouble #2 is that sometimes the readline version is not recent
enough. According to my fading memory, you need version 2.1 or better
(I have 2.2). The check for rl_callback_read_char by configure is not
an arbitrary sanity check. The callback functions are used by R and
have to be there. (This so that R can work with X graphics events).

A quick check on your library would be along the lines of:

[pd at blueberry r-devel]$ nm /usr/lib/libreadline.so | grep callback
00018320 t _rl_callback_newline
00018370 T rl_callback_handler_install
00018490 T rl_callback_handler_remove
000183d0 T rl_callback_read_char

   O__  ---- Peter Dalgaard             Blegdamsvej 3  
  c/ /'_ --- Dept. of Biostatistics     2200 Cph. N   
 (*) \(*) -- University of Copenhagen   Denmark      Ph: (+45) 35327918
~~~~~~~~~~ - (p.dalgaard at biostat.ku.dk)             FAX: (+45) 35327907
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch

More information about the R-help mailing list