使用buildozer将python文件转换为apk时出现构建错误 [英] Build Error while converting python file into apk using buildozer

查看:249
本文介绍了使用buildozer将python文件转换为apk时出现构建错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经使用Kivy在python中制作了一个简单的应用程序,现在我希望将其转换为apk文件,以便可以在我的android手机中使用它. 但是,在转换过程中,我一直在跟踪构建错误.我正在使用buildozer构建apk文件. 我已经检查了所有丢失的文件或目录,但事实并非如此.操作系统:UBUNTU 12.04.错误是:

I have made a simple app in python using Kivy and now I want this to be converted into an apk file so that I can use it in my android mobile. But constantly I am getting following build error while converting it. I am using buildozer for building an apk file. I have checked for any missing files or directory, but that's not the case. OS : UBUNTU 12.04. The Error is :

[aapt] ~/.buildozer/android/platform/android-sdk-21/platform-tools/aapt: error while loading shared libraries: libz.so.1: cannot open shared object file: No such file or directory

BUILD FAILED
~/.buildozer/android/platform/android-sdk-21/tools/ant/build.xml:645: The following error occurred while executing this line:
~/.buildozer/android/platform/android-sdk-21/tools/ant/build.xml:683: null returned: 127

Total time: 1 second
.
.
.
assets/private.mp3: /home/manish/kivy/.buildozer/android/app/sitecustomize.pyo
Traceback (most recent call last):
  File "build.py", line 412, in <module>
    make_package(args)
  File "build.py", line 336, in make_package
    subprocess.check_call([ANT, arg])
  File "/usr/lib/python2.7/subprocess.py", line 511, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['ant', 'debug']' returned non-zero exit status 1
# Command failed: /usr/bin/python2.7 build.py --name 'My Application' --version 1.0 --package org.test.myapp --private /home/manish/kivy/.buildozer/android/app --sdk 14 --minsdk 8 --orientation landscape --window debug

推荐答案

我们需要安装ia32libs.在ubuntu上使用"sudo apt-get install ia32-libs"命令.我在kivy的IRC频道上得到了这个问题的答案,它为我工作.最初我没有安装它,因为它是针对32位系统的.他们说,Android工具仍然需要我们在64位系统上下载并安装ia32-libs.

We need to install ia32libs. use " sudo apt-get install ia32-libs " command on ubuntu. I got this question's answer on IRC channel of kivy and it worked for me. Initially i have not installed it as it is for 32-bit system. They said that android tools still require us to download and install ia32-libs on 64bit systems.

这篇关于使用buildozer将python文件转换为apk时出现构建错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆