Kivy buildozer枕头/枕头错误

时间:2019-03-03 02:55:02

标签: python kivy python-imaging-library buildozer

最近有人能获得pil / pillow在Buildozer上工作吗? 它曾经可以在旧版python-for-android上运行,但没有人可以使用。

我目前正在使用Kivy complete VM 0.5,api 27,sdk 23,ndk 17c。

我已经尝试了将近5个月,仍然没有运气, 我尝试将pil,Pillow添加到buildozer要求中,但没有任何效果...我什至尝试从https://www.lfd.uci.edu/~gohlke/pythonlibs/#pil

下载它

任何帮助将不胜感激。

枕头错误:

ImportError: dlopen failed: cannot locate symbol "jsimd_h2v1_downsample" referenced by /PIL/_imaging.so"

Pil错误:

ImportError: The _imaging C module is not installed

 _imaging C is 64 bit instead of 32 bit

编辑: 与p4a.branch = master

[INFO]:    Prebuilding Pillow for armeabi-v7a
[INFO]:    Pillow has no prebuild_armeabi_v7a, skipping
[INFO]:    Applying patches for Pillow[armeabi-v7a]
[INFO]:    Applying patch patches/fix-docstring.patch
[INFO]:    -> running patch -t -d /home/kivy/Desktop...(and 259 more)
[INFO]:    Applying patch patches/fix-setup.patch
[INFO]:    -> running patch -t -d /home/kivy/Desktop...(and 255 more)
[INFO]:    -> running touch /home/kivy/Desktop/PicApp/...(and 110 more)
[INFO]:    Prebuilding pyjnius for armeabi-v7a
[INFO]:    pyjnius has no prebuild_armeabi_v7a, skipping
[INFO]:    Applying patches for pyjnius[armeabi-v7a]
[INFO]:    Applying patch sdl2_jnienv_getter.patch
[INFO]:    -> running patch -t -d /home/kivy/Desktop...(and 264 more)
      [INFO]:    -> running touch /home/kivy/Desktop/PicApp/...(and 117 more)    
[INFO]:    Prebuilding android for armeabi-v7a
[INFO]:    android has no prebuild_armeabi_v7a, skipping
[INFO]:    -> directory context /home/kivy/Desktop/PicApp/.buildozer/android/platform/build/build/other_builds/android-python2-sdl2/armeabi-v7a__ndk_target_21/android
[INFO]:    <- directory context /home/kivy/Desktop/PicApp/.buildozer/android/platform/python-for-android-new-toolchain
[INFO]:    Prebuilding kivy for armeabi-v7a
[INFO]:    kivy has no prebuild_armeabi_v7a, skipping
[INFO]:    # Building recipes
[INFO]:    Building harfbuzz for armeabi-v7a
[INFO]:    -> directory context /home/kivy/Desktop/PicApp/.buildozer/android/platform/build/build/other_builds/harfbuzz/armeabi-v7a__ndk_target_21/harfbuzz
[INFO]:    -> running configure --without-icu --host...(and 161 more)
           working:  Documentation:  no                      [INFO]:    -> running make -j5
           working: [INFO]:    -> running cp -L src/.libs/libharfbuzz.a ...(and 85 more)
[INFO]:    <- directory context /home/kivy/Desktop/PicApp/.buildozer/android/platform/python-for-android-new-toolchain
[INFO]:    Building hostpython2 for armeabi-v7a
[INFO]:    -> directory context /home/kivy/Desktop/PicApp/.buildozer/android/platform/build/build/other_builds/hostpython2/desktop/hostpython2
[INFO]:    -> directory context /home/kivy/Desktop/PicApp/.buildozer/android/platform/build/build/other_builds/hostpython2/desktop/hostpython2/native-build
[INFO]:    -> running configure
           working: creating Ma[INFO]:    <- directory context /home/kivy/Desktop/PicApp/.buildozer/android/platform/build/build/other_builds/hostpython2/desktop/hostpython2
[INFO]:    -> running cp Modules/Setup.dist /home/ki...(and 127 more)
[INFO]:    -> running make -j 1 -C /home/kivy/Deskto...(and 104 more)
           working: copyin[INFO]:    <- directory context /home/kivy/Desktop/PicApp/.buildozer/android/platform/python-for-android-new-toolchain
[INFO]:    Building jpeg for armeabi-v7a
[INFO]:    -> directory context /home/kivy/Desktop/PicApp/.buildozer/android/platform/build/build/other_builds/jpeg/armeabi-v7a__ndk_target_21/jpeg
[INFO]:    -> running rm -f CMakeCache.txt CMakeFiles/
Traceback (most recent call last):
  File "/usr/lib/python2.7/runpy.py", line 174, in _run_module_as_main
    "__main__", fname, loader, pkg_name)
  File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
    exec code in run_globals
  File "/home/kivy/Desktop/PicApp/.buildozer/android/platform/python-for-android-new-toolchain/pythonforandroid/toolchain.py", line 1081, in <module>
    main()
  File "/home/kivy/Desktop/PicApp/.buildozer/android/platform/python-for-android-new-toolchain/pythonforandroid/toolchain.py", line 1075, in main
    ToolchainCL()
  File "/home/kivy/Desktop/PicApp/.buildozer/android/platform/python-for-android-new-toolchain/pythonforandroid/toolchain.py", line 577, in __init__
    getattr(self, args.subparser_name.replace('-', '_'))(args)
  File "/home/kivy/Desktop/PicApp/.buildozer/android/platform/python-for-android-new-toolchain/pythonforandroid/toolchain.py", line 151, in wrapper_func
    build_dist_from_args(ctx, dist, args)
  File "/home/kivy/Desktop/PicApp/.buildozer/android/platform/python-for-android-new-toolchain/pythonforandroid/toolchain.py", line 200, in build_dist_from_args
    build_recipes(build_order, python_modules, ctx)
  File "pythonforandroid/build.py", line 562, in build_recipes
  File "/home/kivy/Desktop/PicApp/.buildozer/android/platform/python-for-android-new-toolchain/pythonforandroid/recipes/jpeg/__init__.py", line 37, in build_arch
    shprint(sh.cmake, '-G', 'Unix Makefiles',
  File "/usr/local/lib/python2.7/dist-packages/sh.py", line 3349, in __getattr__
    return self.__env[name]
  File "/usr/local/lib/python2.7/dist-packages/sh.py", line 3226, in __getitem__
    raise CommandNotFound(k)
sh.CommandNotFound: cmake
# Command failed: /usr/bin/python -m pythonforandroid.toolchain create --dist_name=PicApp --bootstrap=sdl2 --requirements=hostpython2,python2,kivy==master,plyer,android,Pillow --arch armeabi-v7a --copy-libs --color=always --storage-dir="/home/kivy/Desktop/PicApp/.buildozer/android/platform/build"

1 个答案:

答案 0 :(得分:0)

我之前遇到过这个错误,我先卸载了枕头,然后重新安装了它,对我来说却很简单

如果您使用python3,请在下面的python3中替换python

要卸载

sudo python -m pip uninstall pillow

要安装

sudo python -m pip install pillow