cannot compile numpy in python-for-android revamp

120 views
Skip to first unread message

David Liebman

unread,
Oct 9, 2015, 3:29:48 PM10/9/15
to Python For Android
HI,

I'm trying to build a dist that uses the numpy recipe. I am working on a ubuntu 15.04 desktop. I'm using cython 0.23.3 and kivy 1.8.0 and the new python-for-android revamp. I have inclded the bottom portion of the error output. Should this work? what am I doing wrong?

--------------------------------------------------

Building numpy for armeabi
name is numpy <class 'pythonforandroid.recipes.numpy.NumpyRecipe'>
[INFO]:    numpy apparently isn't already in site-packages
[INFO]:    Building compiled components in numpy
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/build/other_builds/numpy/armeabi/numpy
[INFO]:    running python.host setup.py build_ext -v
           working ...   File "/home/dave/.local/share/python-for-android/build/other_builds/numpy/armeabi/numpy/numpy/           working ...   File "/home/dave/.local/share/python-for-android/build/other_builds/numpy/armeabi/numpy/numpy/           working ...   File "/home/dave/.local/share/python-for-android/build/other_builds/numpy/armeabi/numpy/numpy/           working ...   File "/home/dave/.local/share/python-for-android/build/other_builds/numpy/armeabi/numpy/numpy/           working ... ImportError: /home/dave/.local/share/python-for-android/build/python-installs/AwesomeCNN/lib/python2 ...Traceback (most recent call last):
  File "/home/dave/.local/bin/python-for-android", line 9, in <module>
    load_entry_point('python-for-android==0.3', 'console_scripts', 'python-for-android')()
  File "/home/dave/.local/lib/python2.7/site-packages/python_for_android-0.3-py2.7.egg/pythonforandroid/toolchain.py", line 2875, in main
    ToolchainCL()
  File "/home/dave/.local/lib/python2.7/site-packages/python_for_android-0.3-py2.7.egg/pythonforandroid/toolchain.py", line 2500, in __init__
    getattr(self, args.command)(unknown)
  File "/home/dave/.local/lib/python2.7/site-packages/python_for_android-0.3-py2.7.egg/pythonforandroid/toolchain.py", line 171, in wrapper_func
    args = build_dist_from_args(ctx, dist, args)
  File "/home/dave/.local/lib/python2.7/site-packages/python_for_android-0.3-py2.7.egg/pythonforandroid/toolchain.py", line 2278, in build_dist_from_args
    build_recipes(build_order, python_modules, ctx)
  File "/home/dave/.local/lib/python2.7/site-packages/python_for_android-0.3-py2.7.egg/pythonforandroid/toolchain.py", line 2093, in build_recipes
    recipe.build_arch(arch)
  File "/home/dave/.local/lib/python2.7/site-packages/python_for_android-0.3-py2.7.egg/pythonforandroid/toolchain.py", line 1958, in build_arch
    self.build_compiled_components(arch)
  File "/home/dave/.local/lib/python2.7/site-packages/python_for_android-0.3-py2.7.egg/pythonforandroid/toolchain.py", line 1967, in build_compiled_components
    shprint(hostpython, 'setup.py', 'build_ext', '-v')
  File "/home/dave/.local/lib/python2.7/site-packages/python_for_android-0.3-py2.7.egg/pythonforandroid/toolchain.py", line 131, in shprint
    for line in output:
  File "/home/dave/.local/lib/python2.7/site-packages/sh-1.11-py2.7.egg/sh.py", line 565, in next
    self.wait()
  File "/home/dave/.local/lib/python2.7/site-packages/sh-1.11-py2.7.egg/sh.py", line 500, in wait
    self.handle_command_exit_code(exit_code)
  File "/home/dave/.local/lib/python2.7/site-packages/sh-1.11-py2.7.egg/sh.py", line 516, in handle_command_exit_code
    raise exc(self.ran, self.process.stdout, self.process.stderr)
sh.ErrorReturnCode_1:

  RAN: '/home/dave/.local/share/python-for-android/build/python-installs/AwesomeCNN/bin/python.host setup.py build_ext -v'

  STDOUT:
Running from numpy source directory.
Traceback (most recent call last):
  File "setup.py", line 251, in <module>
    setup_package()
  File "setup.py", line 235, in setup_package
    from numpy.distutils.core import setup
  File "/home/dave/.local/share/python-for-android/build/other_builds/numpy/armeabi/numpy/numpy/distutils/__init__.py", line 9, in <module>
    from . import ccompiler
  File "/home/dave/.local/share/python-for-android/build/other_builds/numpy/armeabi/numpy/numpy/distutils/ccompiler.py", line 16, in <module>
    from numpy.distutils import log
  File "/home/dave/.local/share/python-for-android/build/other_builds/numpy/armeabi/numpy/numpy/distutils/log.py", line 10, in <module>
    from .misc_util import (red_text, default_... (496 more, please see e.stdout)

  STDERR:
--------------------------------------------------


Alexander Taylor

unread,
Oct 10, 2015, 7:03:54 AM10/10/15
to Python For Android
Can you post the full log with the --debug option?

David Liebman

unread,
Oct 10, 2015, 7:47:08 AM10/10/15
to Python For Android
[INFO]:    This python-for-android revamp is an experimental alpha release!
[INFO]:    It should work (mostly), but you may experience missing features or bugs.
[INFO]:    Found Android API target in $ANDROIDAPI
[INFO]:    Available Android APIs are (14, 19, 20, 22)
[INFO]:    Requested API target 14 is available, continuing.
[INFO]:    Found NDK dir in $ANDROIDNDK
[INFO]:    Got NDK version from $ANDROIDNDKVER
[WARNING]: NDK version was set as r10e, but checking the NDK dir claims it is r10e-rc4.
[WARNING]: The build will try to continue, but it may fail and you should check that your setting is correct.
[WARNING]: If the NDK dir result is correct, you don't need to manually set the NDK ver.
[INFO]:    Found virtualenv at /usr/local/bin/virtualenv
[DEBUG]:   Found toolchain version: 4.9
[DEBUG]:   Found toolchain version: 4.8
[DEBUG]:   Found toolchain version: clang3.5
[DEBUG]:   Found toolchain version: clang3.6
[INFO]:    Found the following toolchain versions: ['4.8', '4.9', 'clang3.5', 'clang3.6']
[INFO]:    Picking the latest gcc toolchain, here 4.9
[WARNING]: Missing executable: libtoolize is not installed
[INFO]:    No existing dists meet the given requirements!
[INFO]:    No dist exists that meets your requirements, so one will be built.
[INFO]:    Bootstrap requires recipes ['hostpython2', 'python2', 'pyjnius', 'sdl', 'pygame', 'android', 'kivy']
[INFO]:    No recipe named kivy==master; will attempt to install with pip
[INFO]:    Loaded recipe hostpython2 (depends on [], conflicts ['hostpython3'])
[INFO]:    Loaded recipe pygame (depends on ['python2', 'sdl'], conflicts ['sdl2'])
[INFO]:    Loaded recipe kivy (depends on [('sdl2', 'pygame'), 'pyjnius'])
[INFO]:    Loaded recipe sdl (depends on ['python2', 'pygame_bootstrap_components'], conflicts ['sdl2'])
[INFO]:    Loaded recipe pyjnius (depends on ['python2', ('sdl2', 'sdl')])
[INFO]:    Loaded recipe android (depends on ['pygame'], conflicts ['sdl2'])
[INFO]:    Loaded recipe python2 (depends on ['hostpython2'], conflicts ['python3'])
[INFO]:    Loaded recipe pygame_bootstrap_components (depends on [])
[INFO]:    Found a single valid recipe set (this is good)
[INFO]:    The selected bootstrap is pygame
[INFO]:    # Creating dist with pygame bootstrap
[INFO]:    Dist will have name AwesomeCNN and recipes (pyjnius, kivy==master)
[DEBUG]:   running cp -r /home/dave/.local/lib/python2.7/site-packages/python_for_android-0.3-py2.7.egg/pythonforandroid/bootstraps/pygame/build /home/dave/.local/share/python-for-android/build/bootstrap_builds/pygame
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/build/bootstrap_builds/pygame
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    Recipe build order is ['hostpython2', 'pygame_bootstrap_components', 'python2', 'sdl', 'pygame', 'pyjnius', 'android', 'kivy']
[INFO]:    The requirements (kivy==master) were not found as recipes, they will be installed with pip.
[INFO]:    # Downloading recipes
[INFO]:    Downloading hostpython2
[DEBUG]:   running mkdir -p /home/dave/.local/share/python-for-android/packages/hostpython2
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/packages/hostpython2
[DEBUG]:   running basename http://python.org/ftp/python/2.7.2/Python-2.7.2.tar.bz2
[DEBUG]:       Python-2.7.2.tar.bz2
[INFO]:    hostpython2 download already cached, skipping
[WARNING]: Should check headers here! Skipping for now.
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    Downloading pygame_bootstrap_components
[DEBUG]:   running mkdir -p /home/dave/.local/share/python-for-android/packages/pygame_bootstrap_components
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/packages/pygame_bootstrap_components
[DEBUG]:   running basename https://github.com/inclement/p4a-pygame-bootstrap-components/archive/master.zip
[DEBUG]:       master.zip
[INFO]:    pygame_bootstrap_components download already cached, skipping
[WARNING]: Should check headers here! Skipping for now.
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    Downloading python2
[DEBUG]:   running mkdir -p /home/dave/.local/share/python-for-android/packages/python2
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/packages/python2
[DEBUG]:   running basename http://python.org/ftp/python/2.7.2/Python-2.7.2.tar.bz2
[DEBUG]:       Python-2.7.2.tar.bz2
[INFO]:    python2 download already cached, skipping
[WARNING]: Should check headers here! Skipping for now.
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    Downloading sdl
[INFO]:    Skipping sdl download as no URL is set
[INFO]:    Downloading pygame
[DEBUG]:   running mkdir -p /home/dave/.local/share/python-for-android/packages/pygame
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/packages/pygame
[DEBUG]:   running basename http://pygame.org/ftp/pygame-1.9.1release.tar.gz
[DEBUG]:       pygame-1.9.1release.tar.gz
[INFO]:    pygame download already cached, skipping
[WARNING]: Should check headers here! Skipping for now.
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    Downloading pyjnius
[DEBUG]:   running mkdir -p /home/dave/.local/share/python-for-android/packages/pyjnius
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/packages/pyjnius
[DEBUG]:   running basename https://github.com/kivy/pyjnius/archive/master.zip
[DEBUG]:       master.zip
[INFO]:    pyjnius download already cached, skipping
[WARNING]: Should check headers here! Skipping for now.
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    Downloading android
[INFO]:    Skipping android download as no URL is set
[INFO]:    Downloading kivy
[DEBUG]:   running mkdir -p /home/dave/.local/share/python-for-android/packages/kivy
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/packages/kivy
[DEBUG]:   running basename https://github.com/kivy/kivy/archive/master.zip
[DEBUG]:       master.zip
[INFO]:    kivy download already cached, skipping
[WARNING]: Should check headers here! Skipping for now.
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    # Building all recipes for arch armeabi
[INFO]:    # Unpacking recipes
[INFO]:    Unpacking hostpython2 for armeabi
[DEBUG]:   running basename http://python.org/ftp/python/2.7.2/Python-2.7.2.tar.bz2
[DEBUG]:       Python-2.7.2.tar.bz2
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/build/other_builds/hostpython2/armeabi
[INFO]:    hostpython2 is already unpacked, skipping
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    Unpacking pygame_bootstrap_components for armeabi
[DEBUG]:   running basename https://github.com/inclement/p4a-pygame-bootstrap-components/archive/master.zip
[DEBUG]:       master.zip
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/build/bootstrap_builds/pygame/jni
[INFO]:    pygame_bootstrap_components is already unpacked, skipping
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    Unpacking python2 for armeabi
[DEBUG]:   running basename http://python.org/ftp/python/2.7.2/Python-2.7.2.tar.bz2
[DEBUG]:       Python-2.7.2.tar.bz2
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/build/other_builds/python2/armeabi
[INFO]:    python2 is already unpacked, skipping
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    Unpacking sdl for armeabi
[INFO]:    Skipping sdl unpack as no URL is set
[INFO]:    Unpacking pygame for armeabi
[DEBUG]:   running basename http://pygame.org/ftp/pygame-1.9.1release.tar.gz
[DEBUG]:       pygame-1.9.1release.tar.gz
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/build/other_builds/pygame/armeabi
[INFO]:    pygame is already unpacked, skipping
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    Unpacking pyjnius for armeabi
[DEBUG]:   running basename https://github.com/kivy/pyjnius/archive/master.zip
[DEBUG]:       master.zip
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/build/other_builds/pyjnius-sdl/armeabi
[INFO]:    pyjnius is already unpacked, skipping
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[DEBUG]:   running cp -a /home/dave/.local/lib/python2.7/site-packages/python_for_android-0.3-py2.7.egg/pythonforandroid/recipes/android/src /home/dave/.local/share/python-for-android/build/other_builds/android/armeabi/android
[INFO]:    Unpacking kivy for armeabi
[DEBUG]:   running basename https://github.com/kivy/kivy/archive/master.zip
[DEBUG]:       master.zip
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/build/other_builds/kivy-pygame/armeabi
[INFO]:    kivy is already unpacked, skipping
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    # Prebuilding recipes
[INFO]:    Prebuilding hostpython2 for armeabi
[DEBUG]:   running cp /home/dave/.local/lib/python2.7/site-packages/python_for_android-0.3-py2.7.egg/pythonforandroid/recipes/hostpython2/Setup /home/dave/.local/share/python-for-android/build/other_builds/hostpython2/armeabi/hostpython2/Modules/Setup
[INFO]:    Prebuilding pygame_bootstrap_components for armeabi
[INFO]:    Unpacking pygame bootstrap JNI dir components
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/build/bootstrap_builds/pygame/jni

Traceback (most recent call last):
  File "/usr/lib/python2.7/logging/__init__.py", line 859, in emit
    msg = self.format(record)
  File "/usr/lib/python2.7/logging/__init__.py", line 732, in format
    return fmt.format(record)
  File "/home/dave/.local/lib/python2.7/site-packages/python_for_android-0.3-py2.7.egg/pythonforandroid/toolchain.py", line 61, in format
    return super(LevelDifferentiatingFormatter, self).format(record)
  File "/usr/lib/python2.7/logging/__init__.py", line 471, in format
    record.message = record.getMessage()
  File "/usr/lib/python2.7/logging/__init__.py", line 335, in getMessage
    msg = msg % self.args
TypeError: not all arguments converted during string formatting
Logged from file __init__.py, line 18
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    Prebuilding python2 for armeabi
[INFO]:    Python2 already patched, skipping.
[INFO]:    Prebuilding sdl for armeabi
[INFO]:    sdl has no prebuild_armeabi, skipping
[INFO]:    Prebuilding pygame for armeabi
[INFO]:    Pygame already patched, skipping.
[INFO]:    Prebuilding pyjnius for armeabi
[INFO]:    pyjnius has no prebuild_armeabi, skipping
[INFO]:    Prebuilding android for armeabi
[INFO]:    android has no prebuild_armeabi, skipping
[INFO]:    Prebuilding kivy for armeabi
[INFO]:    kivy has no prebuild_armeabi, skipping
[INFO]:    # Building recipes
[INFO]:    Building hostpython2 for armeabi
[WARNING]: Running hostpython build. Arch is armeabi! This is naughty, need to fix the Arch system!
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/build/other_builds/hostpython2/armeabi/hostpython2
[INFO]:    hostpython already exists, skipping build
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    Building pygame_bootstrap_components for armeabi
[INFO]:    Building python2 for armeabi
[INFO]:    Copying hostpython binary to targetpython folder
[DEBUG]:   running cp /home/dave/.local/share/python-for-android/build/other_builds/hostpython2/armeabi/hostpython2/hostpython /home/dave/.local/share/python-for-android/build/python-installs/AwesomeCNN/bin/python.host
[INFO]:    Building sdl for armeabi
[INFO]:    libsdl.so already exists, skipping sdl build.
[INFO]:    Building pygame for armeabi

Traceback (most recent call last):
  File "/usr/lib/python2.7/logging/__init__.py", line 859, in emit
    msg = self.format(record)
  File "/usr/lib/python2.7/logging/__init__.py", line 732, in format
    return fmt.format(record)
  File "/home/dave/.local/lib/python2.7/site-packages/python_for_android-0.3-py2.7.egg/pythonforandroid/toolchain.py", line 61, in format
    return super(LevelDifferentiatingFormatter, self).format(record)
  File "/usr/lib/python2.7/logging/__init__.py", line 471, in format
    record.message = record.getMessage()
  File "/usr/lib/python2.7/logging/__init__.py", line 335, in getMessage
    msg = msg % self.args
TypeError: not all arguments converted during string formatting
Logged from file __init__.py, line 51
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/build/other_builds/pygame/armeabi/pygame
[INFO]:    hostpython is /home/dave/.local/share/python-for-android/build/python-installs/AwesomeCNN/bin/python.host
[DEBUG]:   running python.host setup.py install -O2
[DEBUG]:       running install
[DEBUG]:       running build
[DEBUG]:       running build_py
[DEBUG]:       running build_ext
[DEBUG]:       building 'pygame.imageext' extension
[DEBUG]:       arm-linux-androideabi-gcc -DANDROID -mandroid -fomit-frame-pointer --sysroot /home/dave/bin/android-ndk-r10e/platforms/android-14/arch-arm -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fno-strict-aliasing -DANDROID -mandroid -fomit-frame-pointer --sysroot /home/dave/bin/android-ndk-r10e/platforms/android-14/arch-arm -I/home/dave/.local/share/python-for-android/build/bootstrap_builds/pygame/jni/png -I/home/dave/.local/share/python-for-android/build/bootstrap_builds/pygame/jni/jpeg -I/home/dave/.local/share/python-for-android/build/bootstrap_builds/pygame/jni/sdl/include -I/home/dave/.local/share/python-for-android/build/bootstrap_builds/pygame/jni/sdl_mixer -I/home/dave/.local/share/python-for-android/build/bootstrap_builds/pygame/jni/sdl_ttf -I/home/dave/.local/share/python-for-android/build/bootstrap_builds/pygame/jni/sdl_image -fPIC -D_REENTRANT -I/usr/include/python2.7 -c src/imageext.c -o build/temp.linux-x86_64-2.7/src/imageext.o
[DEBUG]:       In file included from /usr/include/python2.7/Python.h:8:0,
[DEBUG]:                        from src/pygame.h:75,
[DEBUG]:                        from src/imageext.c:47:
[DEBUG]:       /usr/include/python2.7/pyconfig.h:15:52: fatal error: arm-linux-gnueabi/python2.7/pyconfig.h: No such file or directory
[DEBUG]:        #  include <arm-linux-gnueabi/python2.7/pyconfig.h>
[DEBUG]:                                                           ^
[DEBUG]:       compilation terminated.
[DEBUG]:       error: command 'arm-linux-androideabi-gcc' failed with exit status 1

Traceback (most recent call last):
  File "/home/dave/.local/bin/python-for-android", line 9, in <module>
    load_entry_point('python-for-android==0.3', 'console_scripts', 'python-for-android')()
  File "/home/dave/.local/lib/python2.7/site-packages/python_for_android-0.3-py2.7.egg/pythonforandroid/toolchain.py", line 2875, in main
    ToolchainCL()
  File "/home/dave/.local/lib/python2.7/site-packages/python_for_android-0.3-py2.7.egg/pythonforandroid/toolchain.py", line 2500, in __init__
    getattr(self, args.command)(unknown)
  File "/home/dave/.local/lib/python2.7/site-packages/python_for_android-0.3-py2.7.egg/pythonforandroid/toolchain.py", line 171, in wrapper_func
    args = build_dist_from_args(ctx, dist, args)
  File "/home/dave/.local/lib/python2.7/site-packages/python_for_android-0.3-py2.7.egg/pythonforandroid/toolchain.py", line 2278, in build_dist_from_args
    build_recipes(build_order, python_modules, ctx)
  File "/home/dave/.local/lib/python2.7/site-packages/python_for_android-0.3-py2.7.egg/pythonforandroid/toolchain.py", line 2093, in build_recipes
    recipe.build_arch(arch)
  File "/home/dave/.local/lib/python2.7/site-packages/python_for_android-0.3-py2.7.egg/pythonforandroid/toolchain.py", line 1771, in build_arch
    getattr(self, build)()
  File "/home/dave/.local/lib/python2.7/site-packages/python_for_android-0.3-py2.7.egg/pythonforandroid/recipes/pygame/__init__.py", line 62, in build_armeabi
    shprint(hostpython, 'setup.py', 'install', '-O2', _env=env)

  File "/home/dave/.local/lib/python2.7/site-packages/python_for_android-0.3-py2.7.egg/pythonforandroid/toolchain.py", line 131, in shprint
    for line in output:
  File "/home/dave/.local/lib/python2.7/site-packages/sh-1.11-py2.7.egg/sh.py", line 565, in next
    self.wait()
  File "/home/dave/.local/lib/python2.7/site-packages/sh-1.11-py2.7.egg/sh.py", line 500, in wait
    self.handle_command_exit_code(exit_code)
  File "/home/dave/.local/lib/python2.7/site-packages/sh-1.11-py2.7.egg/sh.py", line 516, in handle_command_exit_code
    raise exc(self.ran, self.process.stdout, self.process.stderr)
sh.ErrorReturnCode_1:

  RAN: '/home/dave/.local/share/python-for-android/build/python-installs/AwesomeCNN/bin/python.host setup.py install -O2'

  STDOUT:
running install
running build
running build_py
running build_ext
building 'pygame.imageext' extension
arm-linux-androideabi-gcc -DANDROID -mandroid -fomit-frame-pointer --sysroot /home/dave/bin/android-ndk-r10e/platforms/android-14/arch-arm -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fno-strict-aliasing -DANDROID -mandroid -fomit-frame-pointer --sysroot /home/dave/bin/android-ndk-r10e/platforms/android-14/arch-arm -I/home/dave/.local/share/python-for-android/build/bootstrap_builds/pygame/jni/png -I/home/dave/.local/share/python-for-android/build/bootstrap_builds/pygame/jni/jpeg -I/home/dave/.local/share/python-for-android/build/bootstrap_builds/pygame/jni/sdl/include -I/home/dave/.local/share/python-for-android/build/bootstrap_builds... (765 more, please see e.stdout)

  STDERR:

David Liebman

unread,
Oct 10, 2015, 7:52:16 AM10/10/15
to Python For Android
I changed the command line a little and still get this output. I removed numpy from the dependencies. This is the command line I used:

~/.local/bin/python-for-android create --debug --dist_name=AwesomeCNN --bootstrap=pygame --requirements=pyjnius,kivy==master

Should I start a new thread with a different title since this no longer refers to numpy alone?

Alexander Taylor

unread,
Oct 10, 2015, 7:56:17 AM10/10/15
to python-...@googlegroups.com
This thread is fine unless it turns out to be some major issue.

Your 'kivy==master' syntax isn't actually valid - if you check the log,
you can see it actually tries to find this in pip. Could you try again
without this? p4a doesn't support this syntax but, as it happens, the
revamp currently pulls the kivy master branch anyway.
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Python For Android" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/python-android/z2imFUvpvmo/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> python-androi...@googlegroups.com
> <mailto:python-androi...@googlegroups.com>.
> For more options, visit https://groups.google.com/d/optout.


signature.asc

David Liebman

unread,
Oct 10, 2015, 8:22:32 AM10/10/15
to Python For Android
This listing comes from the following line:


~/.local/bin/python-for-android create --debug --dist_name=AwesomeCNN --bootstrap=pygame --requirements=pyjnius,kivy

It seems to crash building pygame.



[INFO]:    This python-for-android revamp is an experimental alpha release!
[INFO]:    It should work (mostly), but you may experience missing features or bugs.
[INFO]:    Found Android API target in $ANDROIDAPI
[INFO]:    Available Android APIs are (14, 19, 20, 22)
[INFO]:    Requested API target 14 is available, continuing.
[INFO]:    Found NDK dir in $ANDROIDNDK
[INFO]:    Got NDK version from $ANDROIDNDKVER
[WARNING]: NDK version was set as r10e, but checking the NDK dir claims it is r10e-rc4.
[WARNING]: The build will try to continue, but it may fail and you should check that your setting is correct.
[WARNING]: If the NDK dir result is correct, you don't need to manually set the NDK ver.
[INFO]:    Found virtualenv at /usr/local/bin/virtualenv
[DEBUG]:   Found toolchain version: 4.9
[DEBUG]:   Found toolchain version: 4.8
[DEBUG]:   Found toolchain version: clang3.5
[DEBUG]:   Found toolchain version: clang3.6
[INFO]:    Found the following toolchain versions: ['4.8', '4.9', 'clang3.5', 'clang3.6']
[INFO]:    Picking the latest gcc toolchain, here 4.9
[WARNING]: Missing executable: libtoolize is not installed
[INFO]:    No existing dists meet the given requirements!
[INFO]:    No dist exists that meets your requirements, so one will be built.
[INFO]:    Bootstrap requires recipes ['hostpython2', 'python2', 'pyjnius', 'sdl', 'pygame', 'android', 'kivy']
[INFO]:    Loaded recipe hostpython2 (depends on [], conflicts ['hostpython3'])

[INFO]:    Loaded recipe pygame (depends on ['python2', 'sdl'], conflicts ['sdl2'])
[INFO]:    Loaded recipe kivy (depends on [('sdl2', 'pygame'), 'pyjnius'])
[INFO]:    Loaded recipe sdl (depends on ['python2', 'pygame_bootstrap_components'], conflicts ['sdl2'])
[INFO]:    Loaded recipe pyjnius (depends on ['python2', ('sdl2', 'sdl')])
[INFO]:    Loaded recipe android (depends on ['pygame'], conflicts ['sdl2'])
[INFO]:    Loaded recipe python2 (depends on ['hostpython2'], conflicts ['python3'])
[INFO]:    Loaded recipe pygame_bootstrap_components (depends on [])
[INFO]:    Found a single valid recipe set (this is good)
[INFO]:    The selected bootstrap is pygame
[INFO]:    # Creating dist with pygame bootstrap
[INFO]:    Dist will have name AwesomeCNN and recipes (pyjnius, kivy)

[DEBUG]:   running cp -r /home/dave/.local/lib/python2.7/site-packages/python_for_android-0.3-py2.7.egg/pythonforandroid/bootstraps/pygame/build /home/dave/.local/share/python-for-android/build/bootstrap_builds/pygame
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/build/bootstrap_builds/pygame
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    Recipe build order is ['hostpython2', 'pygame_bootstrap_components', 'python2', 'sdl', 'pygame', 'pyjnius', 'android', 'kivy']
[INFO]:    # Downloading recipes
[INFO]:    Downloading hostpython2
[DEBUG]:   running mkdir -p /home/dave/.local/share/python-for-android/packages/hostpython2
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/packages/hostpython2
[DEBUG]:   running basename http://python.org/ftp/python/2.7.2/Python-2.7.2.tar.bz2
[DEBUG]:       Python-2.7.2.tar.bz2
[INFO]:    hostpython2 download already cached, skipping
[WARNING]: Should check headers here! Skipping for now.
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    Downloading pygame_bootstrap_components
[DEBUG]:   running mkdir -p /home/dave/.local/share/python-for-android/packages/pygame_bootstrap_components
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/packages/pygame_bootstrap_components
[DEBUG]:   running basename https://github.com/inclement/p4a-pygame-bootstrap-components/archive/master.zip
[DEBUG]:       master.zip
[INFO]:    pygame_bootstrap_components download already cached, skipping
[WARNING]: Should check headers here! Skipping for now.
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    Downloading python2
[DEBUG]:   running mkdir -p /home/dave/.local/share/python-for-android/packages/python2
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/packages/python2
[DEBUG]:   running basename http://python.org/ftp/python/2.7.2/Python-2.7.2.tar.bz2
[DEBUG]:       Python-2.7.2.tar.bz2
[INFO]:    python2 download already cached, skipping
[WARNING]: Should check headers here! Skipping for now.
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    Downloading sdl
[INFO]:    Skipping sdl download as no URL is set
[INFO]:    Downloading pygame
[DEBUG]:   running mkdir -p /home/dave/.local/share/python-for-android/packages/pygame
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/packages/pygame
[DEBUG]:   running basename http://pygame.org/ftp/pygame-1.9.1release.tar.gz
[DEBUG]:       pygame-1.9.1release.tar.gz
[INFO]:    pygame download already cached, skipping
[WARNING]: Should check headers here! Skipping for now.
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    Downloading pyjnius
[DEBUG]:   running mkdir -p /home/dave/.local/share/python-for-android/packages/pyjnius
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/packages/pyjnius
[DEBUG]:   running basename https://github.com/kivy/pyjnius/archive/master.zip
[DEBUG]:       master.zip
[INFO]:    pyjnius download already cached, skipping
[WARNING]: Should check headers here! Skipping for now.
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    Downloading android
[INFO]:    Skipping android download as no URL is set
[INFO]:    Downloading kivy
[DEBUG]:   running mkdir -p /home/dave/.local/share/python-for-android/packages/kivy
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/packages/kivy
[DEBUG]:   running basename https://github.com/kivy/kivy/archive/master.zip
[DEBUG]:       master.zip
[INFO]:    kivy download already cached, skipping
[WARNING]: Should check headers here! Skipping for now.
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    # Building all recipes for arch armeabi
[INFO]:    # Unpacking recipes
[INFO]:    Unpacking hostpython2 for armeabi
[DEBUG]:   running basename http://python.org/ftp/python/2.7.2/Python-2.7.2.tar.bz2
[DEBUG]:       Python-2.7.2.tar.bz2
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/build/other_builds/hostpython2/armeabi
[INFO]:    hostpython2 is already unpacked, skipping
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    Unpacking pygame_bootstrap_components for armeabi
[DEBUG]:   running basename https://github.com/inclement/p4a-pygame-bootstrap-components/archive/master.zip
[DEBUG]:       master.zip
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/build/bootstrap_builds/pygame/jni
[INFO]:    pygame_bootstrap_components is already unpacked, skipping
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    Unpacking python2 for armeabi
[DEBUG]:   running basename http://python.org/ftp/python/2.7.2/Python-2.7.2.tar.bz2
[DEBUG]:       Python-2.7.2.tar.bz2
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/build/other_builds/python2/armeabi
[INFO]:    python2 is already unpacked, skipping
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    Unpacking sdl for armeabi
[INFO]:    Skipping sdl unpack as no URL is set
[INFO]:    Unpacking pygame for armeabi
[DEBUG]:   running basename http://pygame.org/ftp/pygame-1.9.1release.tar.gz
[DEBUG]:       pygame-1.9.1release.tar.gz
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/build/other_builds/pygame/armeabi
[INFO]:    pygame is already unpacked, skipping
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[INFO]:    Unpacking pyjnius for armeabi
[DEBUG]:   running basename https://github.com/kivy/pyjnius/archive/master.zip
[DEBUG]:       master.zip
[INFO]:    -> directory context /home/dave/.local/share/python-for-android/build/other_builds/pyjnius-sdl/armeabi
[INFO]:    pyjnius is already unpacked, skipping
[INFO]:    <- directory context /home/dave/workspace/awesome-cnn
[DEBUG]:   running cp -a /home/dave/.local/lib/python2.7/site-packages/python_for_android-0.3-py2.7.egg/pythonforandroid/recipes/android/src /home/dave/.local/share/python-for-android/build/other_builds/android/armeabi/android
[INFO]:    Unpacking kivy for armeabi
[DEBUG]:   running basename https://github.com/kivy/kivy/archive/master.zip

Alexander Taylor

unread,
Oct 10, 2015, 8:38:04 AM10/10/15
to python-...@googlegroups.com
I'm not sure what's wrong - it looks like pygame is maybe referencing
the wrong python.h but I don't know why, and running your p4a calling
line does work for me.

Could you run 'p4a clean_builds' then run the command again, and post
the full (very long) log? It might be important to check what happened
during the python build.
> <https://groups.google.com/d/topic/python-android/z2imFUvpvmo/unsubscribe>.
>
> > To unsubscribe from this group and all its topics, send an email to
> > python-androi...@googlegroups.com <javascript:>
> > <mailto:python-androi...@googlegroups.com <javascript:>>.
> > For more options, visit https://groups.google.com/d/optout
> <https://groups.google.com/d/optout>.
>
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Python For Android" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/python-android/z2imFUvpvmo/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> python-androi...@googlegroups.com
> <mailto:python-androi...@googlegroups.com>.
signature.asc

David Liebman

unread,
Oct 10, 2015, 9:01:48 AM10/10/15
to Python For Android
I piped the output to a text file, but all the colored text was ruined. It's also very long, as you said. I will try to attach it here. if it doesn't attach, I will try to post it some other way.
>     >     /home/dave/bin/android-ndk-r10e/platforms/android-14/arch-arm ...
full.txt

Alexander Taylor

unread,
Oct 10, 2015, 11:09:26 AM10/10/15
to python-...@googlegroups.com
I'm afraid I'm a bit stumped. Would you be able to create an issue for
this on the python-for-android github page, and link to this log in a
pastebin (and maybe also the previous log without the build of all the
other packages)?
signature.asc
Reply all
Reply to author
Forward
0 new messages