Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SDL Error: ... could not load library "libpython2.7.so" ... on Android 4.2.2 #1290

Closed
EinExperte opened this issue May 31, 2018 · 4 comments
Closed

Comments

@EinExperte
Copy link

Hi folks,

today I finally managed to produce my first apk using the latest p4a code from the master branch ...

pip install git+https://github.com/kivy/python-for-android.git
(I ran into a lot of problems with the pip install python-for-android variant)

... and I was happy to install it on my Fairphone 1 (Android 4.2.2) ... just to see it crash on startup :-(
A popup tells me:

SDL Error

An Error occured while trying to start the application. Please try again and/or reinstall.

Error: Cannot load library: soinfo_link_image(linker.cpp:1635): could not load library "libpython2.7.so" needed by "libmain.so"; caused by find_library(linker.cpp:889): "libpython2.7.so" failed to load previously

Exit

(Typos possible, I copied by hand)

The same apk works fine (or at least does not crash) on a newer device (Android 7.0).

I built with the following command:
p4a apk --private $HOME/temp/tjapp --package=org.example.taskjuggler --name "Task Juggler" --version 0.3 --bootstrap=sdl2 --requirements=python2,kivy --dist_name=tjapp

API Version: 16
NDK Version: r10e-rc4
Build-Tools Version: 26.0.2

Any advice?

Thanks,
Christoph

@clevermindgames
Copy link

I have spent several hours last night with exactly the same problem. I am using p4a via buildozer though.
My knowledge is very limited in the subject but hope my experience could be usefull to you until a proper fix is developed: in the end I was able to run my APK on Android 4.x by specifying android.sdk = 24, leaving all other parameters to their default values (such as target API, NDK etc). All other combinations resulted in various crashes from PythonUtil.java, which I also tried to modify with no success and finally reverted to the current master branch version.

@homdx
Copy link

homdx commented Jan 15, 2019

Maybe it's fixed?
#1501

@ghost
Copy link

ghost commented Jan 30, 2019

Yea, should be fixed. I remember more tickets about this and pull requests that went in. I'll close it for now.

@EinExperte hope things will work for you now, let us know if you encounter any more problems!

@ghost ghost closed this as completed Jan 30, 2019
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants