[R] How to compile R with command completion?

Peng Yu pengyu.ut at gmail.com
Wed Sep 30 14:26:45 CEST 2009


On Tue, Sep 29, 2009 at 10:39 PM, Martin Morgan <mtmorgan at fhcrc.org> wrote:
> Peng Yu wrote:
>> On Tue, Sep 29, 2009 at 3:47 PM, Tobias Verbeke
>> <tobias.verbeke at gmail.com> wrote:
>>> Peng Yu wrote:
>>>
>>>> I want to compile R with command completion. But I don't find such an
>>>> option in configure. Can somebody let me know how to enable command
>>>> completion in an R session?
>>> AFAIK this is not an option you set when compiling.
>>> Did you try to type a letter (say 'l') and press the
>>> TAB key ?
>>>
>>> If you are not satisfied, you might want to use
>>> other R editors or development environments (such
>>> as StatET for Eclipse or ESS) which implement
>>> command completion in their idiosyncratic ways.
>>
>> I have an older version of R where I can do command completion (after
>> typing TAB, it will list variables that are starting with the already
>> typed letter. I compiled a newer version R with the default compile
>> options, which does not do command completion.
>>
>> Since the old version can do completion, I believe that there must be
>> a way to configure the new version also do so. Can somebody share your
>> insights with me? Thank you!
>
> On linux this facility is provided by the readline system library; this
> should be configured to be true by default and when available; look at
> the end of the configure output, and check that you have the readline
> headers installed.

I get the following configure output that is related to readline. Why
'rl_completion_matches' doesn't exist? What should I do with it?

checking readline/history.h usability... yes
checking readline/history.h presence... yes
checking for readline/history.h... yes
checking readline/readline.h usability... yes
checking readline/readline.h presence... yes
checking for readline/readline.h... yes
checking for rl_callback_read_char in -lreadline... no
checking for main in -lncurses... yes
checking for rl_callback_read_char in -lreadline... yes
checking for history_truncate_file... yes
checking whether rl_completion_matches exists and is declared... no


checking readline/history.h usability... yes
checking readline/history.h presence... yes
checking for readline/history.h... yes
checking readline/readline.h usability... yes
checking readline/readline.h presence... yes
checking for readline/readline.h... yes
checking for rl_callback_read_char in -lreadline... no
checking for main in -lncurses... yes
checking for rl_callback_read_char in -lreadline... yes
checking for history_truncate_file... yes
checking whether rl_completion_matches exists and is declared... no




More information about the R-help mailing list