Post new topic Reply to topic  [ 6 posts ] 
Author Message
 Post subject: TAB Completion ?
PostPosted: Wed Feb 29, 2012 5:48 pm 

Joined: Sat Oct 01, 2005 11:40 am
Posts: 40
Location: IIT Guwahati, Guwahati, Assam, INDIA
I just now compiled Singular-3-1-4 from source code on Ubuntu-12.04 (development branch), AMD-Athlon Processor server. The compilation was successful. However after compilation I seem to have lost some features of the Singular command window like TAB completion (of command). Further the usual key-strokes like backspace and arrow keys produce their escape characters (e.g. ^H, ^[[A,^[[C, etc). In other words the command window behaves like VT-100 terminal.

Any suggestions?

Thanks in advance.

VInay


Report this post
Top
 Profile  
Reply with quote  
 Post subject: Re: TAB Completion ?
PostPosted: Thu Mar 01, 2012 11:30 am 

Joined: Wed May 25, 2005 4:16 pm
Posts: 275
Install readline (and the development package to readline)
(configure searches for libreadline.a/libreadline.so and readline.h)
Rerun configure and make at least in the subdirectories
Singular and kernel:
Code:
cd Singular
./config.status --recheck
./config.status
cd ../kernel
make install
cd ../Singular
make install


Report this post
Top
 Profile  
Reply with quote  
 Post subject: Re: TAB Completion ?
PostPosted: Thu Mar 01, 2012 6:33 pm 

Joined: Sat Oct 01, 2005 11:40 am
Posts: 40
Location: IIT Guwahati, Guwahati, Assam, INDIA
Ah! Thanks a lot. The libreadline-dev was the culprit. I didnt notice before compilation that this package was missing.

by the way how come it was not detected by config?

-- VInay


Report this post
Top
 Profile  
Reply with quote  
 Post subject: Re: TAB Completion ?
PostPosted: Fri Mar 02, 2012 11:02 am 

Joined: Wed May 25, 2005 4:16 pm
Posts: 275
readline is optional.
If it is not found by configure a different way for input is used,
Depending on the existing libraries there are the following possibilities:
static readline, dynamic readline, emulated readline, fgets.
the Singular command
Code:
system("with");
outputs
(beside other tings) the chosen method


Report this post
Top
 Profile  
Reply with quote  
 Post subject: Re: TAB Completion ?
PostPosted: Sun Mar 04, 2012 6:29 am 

Joined: Sat Oct 01, 2005 11:40 am
Posts: 40
Location: IIT Guwahati, Guwahati, Assam, INDIA
Can you please explain the difference between all 4? And how it is determined?

I could not trace much. I found variables in Singular/configure called ac_cv_*_readline. However I could not find the place these variables are set!

Also I found the #define's called HAVE_DYN_RL, HAVE_READLINE and FEREAD.


-- VInay


Report this post
Top
 Profile  
Reply with quote  
 Post subject: Re: TAB Completion ?
PostPosted: Mon Mar 05, 2012 1:18 pm 

Joined: Wed May 25, 2005 4:16 pm
Posts: 275
static readline: input via readline, requires libreadline.* and readline.h
uses HAVE_READLINE
emulated readline: input with line editing, requires libtermcap or libncurses
or libcurses, uses HAVE_FEREAD
fgets: input via fgets (if all other fail)
dynamic readline: input via readline if libreadline.so is available at runtime
used HAVE_DYN_RL, will never be set automaically by configure
(it is thought for binary distributions: works also without libreadline.so,
but take advantage of it if possible)


Report this post
Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 6 posts ] 

You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

It is currently Fri May 13, 2022 11:07 am
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group