39

I am running Ubuntu 12.04.

I'm trying to a get a particular plugin for vim working and it requires that vim has ruby support enabled (the plugin is command-t).

People tell me that I must go into my vim directory and run

./configure --enable-rubyinterp

When i do this i get the following error:

    no terminal library found
checking for tgetent()... configure: error: NOT FOUND!
      You need to install a terminal library; for example ncurses.
      Or specify the name of the library with --with-tlib.

Now I’ve checked and ncurses-base is installed.

What do I need to do?

3
  • 4
    I think you should install a ncurses-dev library Jul 1, 2012 at 16:35
  • could you provide the contents of src/auto/config.log Jul 1, 2012 at 16:37
  • thank you epsilon, that solved it. Could you make that into answer so i can give you credit
    – Fawkes5
    Jul 1, 2012 at 17:22

5 Answers 5

58

I think you should install a ncurses-dev library.

you can do so by running sudo apt-get install libncurses5-dev libncursesw5-dev

4
  • 1
    I'm running ubuntu 16.10 and couldn't find a package "ncurses-dev" . I finally found that installing libtinfo-dev did the trick. Jan 17, 2017 at 0:39
  • 4
    on ubuntu 16.04: sudo apt-get install ncurses-dev
    – Gary
    Mar 27, 2017 at 16:13
  • Latest apt repositories select libncurses5-dev over ncurses-dev
    – NerdOfCode
    Sep 9, 2019 at 20:32
  • on CentOS: sudo yum install ncurses-devel If fixed this checking for working terminal libraries... Cannot find terminal libraries - configure failed
    – rogerdpack
    Apr 7, 2021 at 17:07
19

Run sudo apt-get build-dep vim to install all the packages that was used to build the vim package from the repositories.

1
  • + 1 for the build-dep command
    – rookiepig
    Sep 27, 2016 at 9:58
14

if you don't have sudo access, the solution is as follows:

download the latest (or whichever) release of ncurses from http://ftp.gnu.org/pub/gnu/ncurses/

run these bash commands:

mkdir ~/usr/local
cd <path_to_ncurses>
tar xzvf <ncurses>.tar.gz # change the tar command if it is not a tar.gz
cd <ncurses>
./configure --prefix=$HOME/usr/local
make
make install
cd <path_to_vim>
LDFLAGS=-L$HOME/usr/local/lib ./configure # then add any options e.g. --prefix=$HOME/usr/local
make
make install

And there you go. It's not often that people don't have sudo access to a machine, but this was my case, and this thread didn't provide the information I needed :) Now it does

1
  • 1
    In my case, the above step is still not good enough. I need to add $HOME/usr/local/lib to LD_LIBRARY_PATH as well. May 2, 2016 at 20:57
1

I'm running ubuntu 16.10 and couldn't get vim 8.0 to compile. Googling the issue told me to install a package ncurses-dev but I couldn't find that package. I finally found that installing package libtinfo-dev did the trick and I was able to compile vim.

0

Based on my experience, I did sudo apt-get install libncurses5-dev libncursesw5-dev.

I was on Ubuntu 14.04. It worked.

3
  • Does it add anything to the accepted answer?
    – Anwar
    May 12, 2017 at 16:23
  • # sudo apt-get install libncurses5-dev libncursesw5-dev Reading package lists... Done Building dependency tree Reading state information... Done libncurses5-dev is already the newest version (6.0+20160213-1ubuntu1). libncursesw5-dev is already the newest version (6.0+20160213-1ubuntu1). 0 upgraded, 0 newly installed, 0 to remove and 40 not upgraded. ............................still getting err : /usr/bin/ld: help.o: undefined reference to symbol 'delwin@@NCURSES_5.0.19991023' Oct 17, 2017 at 12:06
  • //usr/local/lib/libncurses.so.5: error adding symbols: DSO missing from command line collect2: error: ld returned 1 exit status Makefile:18: recipe for target 'omnitty' failed make: *** [omnitty] Error 1 Oct 17, 2017 at 12:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.