使用buildozer编译Android应用程序时出错

时间:2020-07-21 14:32:07

标签: python android compilation kivy

我正在尝试使用buildozer编译适用于android的kivy painter应用程序,但出现此错误:

# Check configuration tokens
Traceback (most recent call last):
  File "c:\users\siuba\appdata\local\programs\python\python37\lib\runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "c:\users\siuba\appdata\local\programs\python\python37\lib\runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "C:\Users\siuba\AppData\Local\Programs\Python\Python37\Scripts\buildozer.exe\__main__.py", line 7, in <module>
  File "c:\users\siuba\appdata\local\programs\python\python37\lib\site-packages\buildozer\scripts\client.py", line 13, in main
    Buildozer().run_command(sys.argv[1:])
  File "c:\users\siuba\appdata\local\programs\python\python37\lib\site-packages\buildozer\__init__.py", line 1040, in run_command
    print('Unknown command/target {}'.format(self.translate_target(command, inverse=True)))
AttributeError: 'Buildozer' object has no attribute 'translate_target'

有人知道如何解决吗?

我的配置:

1 个答案:

答案 0 :(得分:0)

来自buildozer documentation

您必须具有Linux或OSX计算机才能进行编译 Android。

不支持

Windows。您可以通过使计算机双启动Linux(我使用Ubuntu)或安装WSL来解决此问题。