-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Why an error occurs 'python-for-android cannot continue; aborting'? #1266
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
Comments
I'm not sure what's wrong here, but it looks like p4a is maybe getting confused between the crystax NDK and the one in ~/.buildozer. Perhaps this is due to a bug somewhere. Does it work if you either delete the ~/.buildozer version, or the crystax ndk (since you're using python2 you don't need the crystax ndk)? |
Remove folder ~/.buildozer. from setuptools import setup, find_packages
from distutils.extension import Extension
from Cython.Distutils import build_ext
from os.path import join, dirname
packages = find_packages()
with open(join(dirname(__file__), 'version.txt'), 'r') as fileh:
version = fileh.read().strip()
options = {'apk': {'window': None,
'requirements': 'sdl2,kivy,python2,pygments,jedi',
'android-api': 19,
'ndk-dir': '/home/zavulon/Opt/android-ndk-r9c',
'sdk-dir': '/home/zavulon/Opt/android-sdk-23',
'dist-name': 'pyonic_python2',
'ndk-version': '9c',
'sdk-version': '23',
'package': 'net.inclem.pyonicinterpreter',
'permission': 'INTERNET',
'service': 'interpreter:interpreter_subprocess/interpreter.py',
# 'service': 'pip:interpreter_subprocess/interpreter.py',
# 'services': 'pip:interpreter_subprocess/interpreter.py;interpreter:interpreter_subprocess/interpreter.py',
'arch': 'armeabi-v7a',
'icon': 'build_assets/icon_py2-96.png',
'presplash': 'build_assets/presplash.png',
'whitelist': 'build_assets/whitelist.txt',
'local-recipes': './p4a_recipes',
# 'release': None,
# 'debug': None,
}}
setup(
name='Pyonic Python 2 interpreter',
version=version,
description='A Python mobile IDE experiment',
author='Alexander Taylor',
author_email='alexanderjohntaylor@gmail.com',
packages=packages,
options=options,
package_data={'pyonic': ['*.py', '*.kv'],
'pyonic/interpreter_subprocess': ['*.py'],
'pyonic/assets': ['*.ttf', '*.txt']}
) Get error: running apk
Including pyonic/pipinterface.py
Including pyonic/interpreterwrapper.py
Including pyonic/interpreter.py
Including pyonic/__init__.py
Including pyonic/utils.py
Including pyonic/editor.py
Including pyonic/menu.py
Including pyonic/main.py
Including pyonic/settings.py
Including pyonic/android_runnable.py
Including pyonic/widgets.py
Including pyonic/jediinterface.py
Including pyonic/main.kv
Including pyonic/interpreter.kv
Including pyonic/pipinterface.kv
Including pyonic/menu.kv
Including pyonic/editor.kv
Including pyonic/settings.kv
Including pyonic/interpreter_subprocess/interpreter.py
Including pyonic/assets/fontello.ttf
Including pyonic/assets/LICENSE.txt
[INFO]: Will compile for the following archs: armeabi-v7a
[INFO]: Getting Android API version from user argument
[INFO]: Available Android APIs are (9, 19, 23)
[INFO]: Requested API target 19 is available, continuing.
[INFO]: Getting NDK dir from from user argument
[INFO]: Got NDK version from from user argument
[INFO]: Using Google NDK r9c
[INFO]: Found virtualenv at /usr/local/bin/virtualenv
[INFO]: ccache is missing, the build will not be optimized in the future.
[WARNING]: include directory doesn't exist: /home/zavulon/Opt/android-ndk-r9c/sysroot/usr/include/arm-linux-androideabi
[INFO]: Found the following toolchain versions: ['4.6', '4.8', 'clang3.3']
[INFO]: Picking the latest gcc toolchain, here 4.8
[ERROR]: python-for-android cannot continue; aborting |
Same problem here, I'm using Python 3.5, Crystax, Gradle (no buildozer) The 'sysroot' include path is explicitly added in pythonforandroid/build.py line 365 Workaround : Comment out the test - p4a builds and the apk installs and runs. |
Thanks for this note, I hadn't looked at the code to understand the problem, but what you've pointed out makes it clear that the build was broken by a recent merge. I've reverted that change, does the p4a master branch work for you now? Sorry about that. |
Confirmed, I get running apk with the new master. Thanks for the fast response. And it is amazingly cool to see Kivy running on my phone :) I installed python-for-android using (and I assume the git form would also work): FYI I use Cython 0.24.1 , and Kivy 1.10.1dev. No idea if these particular versions are required now. |
Great, sorry again about breaking things, that's my mistake. I'll try to improve the tests to make sure such a thing can't slip through again. As far as versions go, using Kivy master with any recent cython version should be fine, I think. Kivy master should become Kivy 1.10.1 stable soon. |
Installed python-for-android using the instructions:
I am trying to build a project - https://github.com/inclement/Pyonic-interpreter
Here is the code from Pyonic-interprete/sertup.py (pointed only his way to crystax-ndk):
Run build:
Get error:
What is the problem?
Using Python 2.7
The text was updated successfully, but these errors were encountered: