grin icon indicating copy to clipboard operation
grin copied to clipboard

ncurses error when using binary

Open faddat opened this issue 7 years ago • 23 comments

This release:

https://github.com/mimblewimble/grin/releases/tag/v0.4.2

When using the v0.4.2 binary, I get the following ncurses error:

./grin: error while loading shared libraries: libncursesw.so.5: cannot open shared object file: No such file or directory

I don't get this error when building using cargo from source code. When I build it myself Grin works just fine :). Arch Linux. Happy to investigate further.

faddat avatar Dec 09 '18 02:12 faddat

Hey @faddat, just curious if you tried to install ncurses on your Arch linux?

quentinlesceller avatar Dec 11 '18 15:12 quentinlesceller

I believe this is because Arch Linux has already the newer version of libncursesw.so - libncursesw.so.6:

$ ls /usr/lib/libncursesw.so.6
/usr/lib/libncursesw.so.6
$ ls /usr/lib/libncursesw.so.5
ls: cannot access '/usr/lib/libncursesw.so.5': No such file or directory

Creating a simlink 6 -> 5 works just fine:

ln -s /usr/lib/libtinfo.so.6 /usr/lib/libtinfo.so.5

and exactly the same goes for /usr/lib/libtinfo.so. Grin lunches just fine after these fixes

tsusanka avatar Jan 15 '19 20:01 tsusanka

I installed 5 on a vultr server running Ubuntu 18.xx, still get the error. Not paying attention thought I might need the newer 6.1, so compiled and installed. Same error of course and the simlink back to 5 still gives initial error. Going to try rolling back to good old 16.xx I think.

Lazydayz137 avatar Jan 20 '19 20:01 Lazydayz137

Works like a charm, no ncurses install required(5 already there) on a Vultr Ubuntu 16.04 clean install w/upgrades. Just as an update to my previous comment. Doesn't change OP issue.

Lazydayz137 avatar Jan 20 '19 20:01 Lazydayz137

same issue here, grin 1.0.1 using Manjaro (arch based)

jeroenev avatar Feb 10 '19 19:02 jeroenev

fixed this problem in ubuntu 18.10, grin 1.0.1:

cd /lib/x86_64-linux-gnu
ln -s libncursesw.so.6 libncursesw.so.5
ln -s libtinfo.so.6 libtinfo.so.5

in ubuntu 18.04, this problem don't exist, and these two file is appeared in version 5.

jasonzhouu avatar Feb 10 '19 20:02 jasonzhouu

cding into /usr/lib/ and using your symlink commands from there seems to solve the issue on manjaro (and probably Arch as well)

jeroenev avatar Feb 11 '19 19:02 jeroenev

Looks like the a distro related error and not a grin error itself. Closing.

quentinlesceller avatar Mar 26 '19 14:03 quentinlesceller

Seems to me like an issue with grin not recognizing libncurse version 6, only version 5 Once ubuntu updates to v6 this issue will also occur there

jeroenev avatar Mar 27 '19 09:03 jeroenev

Seems like it already occurs in version 18.10 reading the comments above

jeroenev avatar Mar 27 '19 09:03 jeroenev

I believe this is because Arch Linux has already the newer version of libncursesw.so - libncursesw.so.6:

$ ls /usr/lib/libncursesw.so.6
/usr/lib/libncursesw.so.6
$ ls /usr/lib/libncursesw.so.5
ls: cannot access '/usr/lib/libncursesw.so.5': No such file or directory

Creating a simlink 6 -> 5 works just fine:

ln -s /usr/lib/libtinfo.so.6 /usr/lib/libtinfo.so.5

and exactly the same goes for /usr/lib/libtinfo.so. Grin lunches just fine after these fixes

After making the link, it comes with another error:

Segmentation fault (core dumped)

cool007zqw avatar Apr 13 '19 02:04 cool007zqw

@cool007zqw try the code from jasonzhouu, that fixed the errors for me on Manjaro

jeroenev avatar Apr 15 '19 08:04 jeroenev

fixed this problem in ubuntu 18.10, grin 1.0.1:

cd /lib/x86_64-linux-gnu
ln -s libncursesw.so.6 libncursesw.so.5
ln -s libtinfo.so.6 libtinfo.so.5

in ubuntu 18.04, this problem don't exist, and these two file is appeared in version 5.

Ubuntu 19.04 Fix for me ! Thx

mjssln avatar May 07 '19 12:05 mjssln

I am on Ubuntu 19.04 and the symlinks have not solved the problem for me. After running the above commands, trying to run grin gives me these errors:

./grin: /lib/x86_64-linux-gnu/libtinfo.so.5: version NCURSES_TINFO_5.0.19991023' not found (required by ./grin) ./grin: /lib/x86_64-linux-gnu/libncursesw.so.5: versionNCURSESW_5.6.20061217' not found (required by ./grin) ./grin: /lib/x86_64-linux-gnu/libncursesw.so.5: version `NCURSESW_5.1.20000708' not found (required by ./grin)

Thank you for any help you can provide.

FTLIan avatar Sep 04 '19 14:09 FTLIan

Hi @FTLIan, I will spin up a 19.04 VM and see if I can help you.

quentinlesceller avatar Sep 04 '19 14:09 quentinlesceller

Hi @FTLIan unfortunately I was not able to run the binaries on Ubuntu 19.04. I opened the following issue https://github.com/mimblewimble/grin/issues/3022.

quentinlesceller avatar Sep 04 '19 16:09 quentinlesceller

Resolves:

sudo apt-get install -y libncursesw5

Sky-Bly avatar Jan 27 '20 05:01 Sky-Bly

@quentinlesceller I just encountered this issue as well (Debian Buster) with newer versions of libncurses already installed on the system.

@Sky-Bly's fix worked for me (thanks for that)

sudo apt-get install -y libncursesw5

...but I would tend to agree with @jeroen7s's comment above:

Seems to me like an issue with grin not recognizing libncurse version 6, only version 5

Would be nice if we could get this addressed somehow, I don't think it's obvious for end users that they need to have a specific older version of ncurses installed in order for the binary to work. Perhaps makes sense to reopen?

lehnberg avatar Apr 08 '20 20:04 lehnberg

I agree, fixing small things like this matter easy to install/use, with no hurdles is good for adoption

slicken avatar Apr 09 '20 13:04 slicken

I'll take a look.

quentinlesceller avatar Apr 09 '20 14:04 quentinlesceller