Android compile error using buildozer(Android使用buildozer编译错误)
问题描述
我正在尝试使用 buildozer 编译一个 .apk(这个).但我不断收到下面的命令失败消息.我尝试使用不同的 python 路径,重新安装 buildozer,使用不同的 buildozer 路径,从 Mac HD 编译,使用 sudo 编译,不同的 cython 版本.没有工作.
I am trying to compile an .apk (this one) using buildozer. But I keep getting the command failed message below. I've tried using a different python path, reinstalling buildozer, using different buildozer paths, compiling from Mac HD, compiling with sudo, a different cython version. None work.
Traceback(最近一次调用最后一次):文件build.py",第 497 行,在make_package(args)make_package 中的文件build.py",第 351 行subprocess.check_call([ANT, arg])文件/usr/local/Cellar/python/2.7.8_1/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py",第 540 行,在 check_call引发 CalledProcessError(retcode, cmd)subprocess.CalledProcessError: Command '['ant', 'debug']' 返回非零退出状态 1
Traceback (most recent call last): File "build.py", line 497, in make_package(args) File "build.py", line 351, in make_package subprocess.check_call([ANT, arg]) File "/usr/local/Cellar/python/2.7.8_1/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py", line 540, in check_call raise CalledProcessError(retcode, cmd) subprocess.CalledProcessError: Command '['ant', 'debug']' returned non-zero exit status 1
命令失败:/usr/local/Cellar/python/2.7.8_1/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python build.py --name 'My Application'--version 1.2.0 --package org.test.myapp --private/Users/user/Documents/Py/kvapk/.buildozer/android/app --sdk 14 --minsdk 8 --permission INTERNET --permission ACCESS_NETWORK_STATE--orientation 纵向调试
Command failed: /usr/local/Cellar/python/2.7.8_1/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python build.py --name 'My Application' --version 1.2.0 --package org.test.myapp --private /Users/user/Documents/Py/kvapk/.buildozer/android/app --sdk 14 --minsdk 8 --permission INTERNET --permission ACCESS_NETWORK_STATE --orientation portrait debug
我在 OSX Mavericks 上使用 python 2.7.5、kivy 1.8.0、cython 0.19 和 buildozer 0.17
I'm on OSX Mavericks using python 2.7.5, kivy 1.8.0, cython 0.19 and buildozer 0.17
这是总输出:https://gist.github.com/feynman21/29d2f02c387112f2900b
推荐答案
这是 buildozer 无法安装 Android 构建工具的问题.希望这将很快得到解决.在此之前,您可以通过手动安装构建工具 (https://github.com/kivy/buildozer/issues/146#issuecomment-57061269):
This is an issue with buildozer failing to install the Android build-tools. Hopefully this will be fixed soon. Until then, you can work around this by manually installing build-tools (https://github.com/kivy/buildozer/issues/146#issuecomment-57061269):
- 运行
~/.buildozer/android/platform/android-sdk-21/tools/android
以启动 Android SDK Manager.(如果您有不同的 SDK 版本,请将android-sdk-21
替换为相应的文件夹) - 点击窗口底部的
Deselect All
链接,并选中Android SDK Build-tools -- 20"旁边的复选框.(注意:确切的版本无关紧要,只需选择可用的最新版本即可.) - 点击
Install 1 package...
按钮. - 单击
接受许可
,然后单击安装
按钮.李> - 关闭 SDK 管理器并继续使用 buildozer.
- Run
~/.buildozer/android/platform/android-sdk-21/tools/android
to launch the Android SDK Manager. (If you have a different SDK version, replaceandroid-sdk-21
with the appropriate folder) - Click the
Deselect All
link at the bottom of the window, and check the box next to "Android SDK Build-tools -- 20". (Note: the exact version doesn't matter, just pick the newest version available.) - Click the
Install 1 package...
button. - Click
Accept License
and then click theInstall
button. - Close the SDK Manager and resume working with buildozer.
这篇关于Android使用buildozer编译错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:Android使用buildozer编译错误


基础教程推荐
- 如何从 logcat 中删除旧数据? 2022-01-01
- iPhone - 获取给定地点/时区的当前日期和时间并将其与同一地点的另一个日期/时间进行比较的正确方法 2022-01-01
- navigator.geolocation.getCurrentPosition 在 Android 浏览器上 2022-01-01
- libGDX 从精灵或纹理中获取像素颜色 2022-01-01
- NSString intValue 不能用于检索电话号码 2022-01-01
- Android:getLastKnownLocation(LocationManager.NETWORK_PROVIDER 2022-01-01
- Cocos2d iPhone 非矩形精灵触摸检测 2022-01-01
- iOS4 创建后台定时器 2022-01-01
- 通过重定向链接在 Google Play 中打开应用 2022-01-01
- AdMob 广告未在模拟器中显示 2022-01-01