apk build error: libtinfo.so.5: cannot open shared object file: No such file or directory
p4a version: git master os: opensuse tumbleweed
I tried to build apk with command:
p4a apk --private /home/z/pproj/paradox_ssh/ --version=1.7 --bootstrap=sdl2 --local-recipes=./recipes --requirements=python3,kivy-async,openssl,sqlite3,pil,requests,sdl2,plyer --whitelist=./whitelist.txt --permission=CALL_PHONE --permission=INTERNET --orientation=portrait --package=org.spbelect.paradox2 --name="paradox2" --release
got an error about missing lib, which i could not find in my distro:
libtinfo.so.5: cannot open shared object file: No such file or directory
full p4a log: https://gist.github.com/Fak3/c6db4050eca33b9c7571c1e508f54f24
I wonder what is this lib and is there any way to resolve this dependency?
This is new to me and I'm not sure what would cause it. I don't recognise the dependency, so either it's installed by chance (or I missed it) in our testing environment, or this message really arises from some other issue.
It's probably worth installing the lib if possible, in my distro it comes from the ncurses5-compat-libs package.
Yes I would definitely just install this system library. On Ubuntu it's via:
sudo apt install libtinfo5
And probably also:
sudo apt install libncurses5-dev libncursesw5-dev
The issue was also described in https://github.com/kivy/buildozer/issues/841 Addressing https://github.com/kivy/python-for-android/issues/1750 should help with this kind of issues.
Thanks! I only had libncurses6 installed. It worked after i installed libncurses5. Perhaps it could be added to the documentation: https://python-for-android.readthedocs.io/en/latest/quickstart/#installing-dependencies only mentions libncurses without version.
I just hit this myself on a new install, it should definitely be added to the documentation. Perhaps we can also fix the requirement for it, I don't think it's actually necessary for Python to build, it probably thinks it needs the library due to some quirk of the android build environment.
you can also create a symlink so that 5 points to 6 (ln -s /usr/lib/libtinfo.so.6 /usr/lib/libtinfo.so.5) - probably there's a command somewhere that just needs to be more general.