"file too short" error while loading libtermcap.so / libncurses.so
11,410
The libncruses library is actually in /lib/libncurses.so.5.
Just make a symlink to /lib/libncurses.so.5 (or the right version, /lib/libncurses.so.5.9 in my system) into /usr/lib/libtermcap.so.2 and it will work.
Related videos on Youtube
Author by
Sukanto
Updated on September 18, 2022Comments
-
Sukanto almost 2 years
On my Ubuntu 11.10, I am running a version of gdb for different target other than host machine and I am getting the following error:
xxxxx-none-linux-gnu-gdb: error while loading shared libraries: /usr/lib/libtermcap.so.2: file too short
Following is the list of my libncurses and libtermcap on my host:
$ ls -l /usr/lib/libtermcap.* lrwxrwxrwx 1 root root 12 2011-09-17 00:59 /usr/lib/libtermcap.a -> libncurses.a lrwxrwxrwx 1 root root 13 2011-09-17 00:59 /usr/lib/libtermcap.so -> libncurses.so lrwxrwxrwx 1 root root 22 2011-12-05 17:32 /usr/lib/libtermcap.so.2 -> /usr/lib/libncurses.so $ ls -l /usr/lib/libncurses* -rw-r--r-- 1 root root 221876 2011-09-17 00:59 /usr/lib/libncurses.a -rw-r--r-- 1 root root 113216 2011-09-17 00:59 /usr/lib/libncurses++.a -rw-r--r-- 1 root root 31 2011-09-17 00:59 /usr/lib/libncurses.so $ cat /usr/lib/libncurses.so INPUT(libncurses.so.5 -ltinfo) $ uname -a Linux hostname 3.0.0-13-generic-pae #22-Ubuntu SMP Wed Nov 2 15:17:35 UTC 2011 i686 i686 i386 GNU/Linux
How to get over this issue ?
-
Sukanto over 12 yearsAfter resolving this issue as per Pere's suggestion, I got a similar issue with libexpat.so.0. Had to do the following:
ln -s /lib/i386-linux-gnu/libexpat.so.1 /lib/libexpat.so.0
-