当将一个非常简单的“ Hello World” kivy文件编译为apk时。但是发生了错误。
[INFO]: -> running autogen.sh
Exception in thread background thread for pid 10006:
Traceback (most recent call last):
File "/usr/lib/python3.5/threading.py", line 914, in _bootstrap_inner
self.run()
File "/usr/lib/python3.5/threading.py", line 862, in run
self._target(*self._args, **self._kwargs)
File "/usr/local/lib/python3.5/dist-packages/sh-1.12.14-py3.5.egg/sh.py", line 1540, in wrap
fn(*args, **kwargs)
File "/usr/local/lib/python3.5/dist-packages/sh-1.12.14-py3.5.egg/sh.py", line 2459, in background_thread
handle_exit_code(exit_code)
File "/usr/local/lib/python3.5/dist-packages/sh-1.12.14-py3.5.egg/sh.py", line 2157, in fn
return self.command.handle_command_exit_code(exit_code)
File "/usr/local/lib/python3.5/dist-packages/sh-1.12.14-py3.5.egg/sh.py", line 815, in handle_command_exit_code
raise exc
sh.ErrorReturnCode_127:
RAN: /mnt/d/project1/test/.buildozer/android/platform/build-armeabi-v7a/build/other_builds/libffi/armeabi-v7a__ndk_target_21/libffi/autogen.sh
STDOUT:
/mnt/d/project1/test/.buildozer/android/platform/build-armeabi-v7a/build/other_builds/libffi/armeabi-v7a__ndk_target_21/libffi/autogen.sh: 2: exec: autoreconf: not found
STDERR:
Traceback (most recent call last):
File "/usr/lib/python3.5/runpy.py", line 184, in _run_module_as_main
"__main__", mod_spec)
File "/usr/lib/python3.5/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "/mnt/d/project1/test/.buildozer/android/platform/python-for-android/pythonforandroid/toolchain.py", line 1192, in <module>
main()
File "/mnt/d/project1/test/.buildozer/android/platform/python-for-android/pythonforandroid/entrypoints.py", line 18, in main
ToolchainCL()
File "/mnt/d/project1/test/.buildozer/android/platform/python-for-android/pythonforandroid/toolchain.py", line 668, in __init__
getattr(self, args.subparser_name.replace('-', '_'))(args)
File "/mnt/d/project1/test/.buildozer/android/platform/python-for-android/pythonforandroid/toolchain.py", line 153, in wrapper_func
build_dist_from_args(ctx, dist, args)
File "/mnt/d/project1/test/.buildozer/android/platform/python-for-android/pythonforandroid/toolchain.py", line 206, in build_dist_from_args
args, "ignore_setup_py", False
File "/mnt/d/project1/test/.buildozer/android/platform/python-for-android/pythonforandroid/build.py", line 577, in build_recipes
recipe.build_arch(arch)
File "/mnt/d/project1/test/.buildozer/android/platform/python-for-android/pythonforandroid/recipes/libffi/__init__.py", line 33, in build_arch
shprint(sh.Command('./autogen.sh'), _env=env)
File "/mnt/d/project1/test/.buildozer/android/platform/python-for-android/pythonforandroid/logger.py", line 180, in shprint
for line in output:
File "/usr/local/lib/python3.5/dist-packages/sh-1.12.14-py3.5.egg/sh.py", line 863, in next
self.wait()
File "/usr/local/lib/python3.5/dist-packages/sh-1.12.14-py3.5.egg/sh.py", line 792, in wait
self.handle_command_exit_code(exit_code)
File "/usr/local/lib/python3.5/dist-packages/sh-1.12.14-py3.5.egg/sh.py", line 815, in handle_command_exit_code
raise exc
sh.ErrorReturnCode_127:
RAN: /mnt/d/project1/test/.buildozer/android/platform/build-armeabi-v7a/build/other_builds/libffi/armeabi-v7a__ndk_target_21/libffi/autogen.sh
STDOUT:
/mnt/d/project1/test/.buildozer/android/platform/build-armeabi-v7a/build/other_builds/libffi/armeabi-v7a__ndk_target_21/libffi/autogen.sh: 2: exec: autoreconf: not found
================================================ ============================= 这只是一个带有kivy文件的非常简单的py,但我不希望出现此错误。 所以,请帮助我! 非常感谢!!!
更新:安装了autoconf后,我尝试再次编译,但是发生了另一个错误。
日志:
Exception in thread background thread for pid 9679:
Traceback (most recent call last):
File "/usr/lib/python3.5/threading.py", line 914, in _bootstrap_inner
self.run()
File "/usr/lib/python3.5/threading.py", line 862, in run
self._target(*self._args, **self._kwargs)
File "/usr/local/lib/python3.5/dist-packages/sh-1.12.14-py3.5.egg/sh.py", line 1540, in wrap
fn(*args, **kwargs)
File "/usr/local/lib/python3.5/dist-packages/sh-1.12.14-py3.5.egg/sh.py", line 2459, in background_thread
handle_exit_code(exit_code)
File "/usr/local/lib/python3.5/dist-packages/sh-1.12.14-py3.5.egg/sh.py", line 2157, in fn
return self.command.handle_command_exit_code(exit_code)
File "/usr/local/lib/python3.5/dist-packages/sh-1.12.14-py3.5.egg/sh.py", line 815, in handle_command_exit_code
raise exc
sh.ErrorReturnCode_1:
RAN: /mnt/d/project1/test/.buildozer/android/platform/build-armeabi-v7a/build/other_builds/libffi/armeabi-v7a__ndk_target_21/libffi/autogen.sh
STDOUT:
autoreconf: Entering directory `.'
autoreconf: configure.ac: not using Gettext
autoreconf: running: aclocal --force -I m4
autoreconf: configure.ac: tracing
autoreconf: configure.ac: not using Libtool
autoreconf: running: /usr/bin/autoconf --force
configure.ac:41: error: possibly undefined macro: AC_PROG_LIBTOOL
If this token and others are legitimate, please use m4_pattern_allow.
See the Autoconf documentation.
autoreconf: /usr/bin/autoconf failed with exit status: 1
STDERR:
Traceback (most recent call last):
File "/usr/lib/python3.5/runpy.py", line 184, in _run_module_as_main
"__main__", mod_spec)
File "/usr/lib/python3.5/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "/mnt/d/project1/test/.buildozer/android/platform/python-for-android/pythonforandroid/toolchain.py", line 1192, in <module>
main()
File "/mnt/d/project1/test/.buildozer/android/platform/python-for-android/pythonforandroid/entrypoints.py", line 18, in main
ToolchainCL()
File "/mnt/d/project1/test/.buildozer/android/platform/python-for-android/pythonforandroid/toolchain.py", line 668, in __init__
getattr(self, args.subparser_name.replace('-', '_'))(args)
File "/mnt/d/project1/test/.buildozer/android/platform/python-for-android/pythonforandroid/toolchain.py", line 153, in wrapper_func
build_dist_from_args(ctx, dist, args)
File "/mnt/d/project1/test/.buildozer/android/platform/python-for-android/pythonforandroid/toolchain.py", line 206, in build_dist_from_args
args, "ignore_setup_py", False
File "/mnt/d/project1/test/.buildozer/android/platform/python-for-android/pythonforandroid/build.py", line 577, in build_recipes
recipe.build_arch(arch)
File "/mnt/d/project1/test/.buildozer/android/platform/python-for-android/pythonforandroid/recipes/libffi/__init__.py", line 33, in build_arch
shprint(sh.Command('./autogen.sh'), _env=env)
File "/mnt/d/project1/test/.buildozer/android/platform/python-for-android/pythonforandroid/logger.py", line 180, in shprint
for line in output:
File "/usr/local/lib/python3.5/dist-packages/sh-1.12.14-py3.5.egg/sh.py", line 863, in next
self.wait()
File "/usr/local/lib/python3.5/dist-packages/sh-1.12.14-py3.5.egg/sh.py", line 792, in wait
self.handle_command_exit_code(exit_code)
File "/usr/local/lib/python3.5/dist-packages/sh-1.12.14-py3.5.egg/sh.py", line 815, in handle_command_exit_code
raise exc
sh.ErrorReturnCode_1:
RAN: /mnt/d/project1/test/.buildozer/android/platform/build-armeabi-v7a/build/other_builds/libffi/armeabi-v7a__ndk_target_21/libffi/autogen.sh
STDOUT:
autoreconf: Entering directory `.'
autoreconf: configure.ac: not using Gettext
autoreconf: running: aclocal --force -I m4
autoreconf: configure.ac: tracing
autoreconf: configure.ac: not using Libtool
autoreconf: running: /usr/bin/autoconf --force
configure.ac:41: error: possibly undefined macro: AC_PROG_LIBTOOL
If this token and others are legitimate, please use m4_pattern_allow.
See the Autoconf documentation.
autoreconf: /usr/bin/autoconf failed with exit status: 1
STDERR:
我现在需要编译它,但是我不知道如何解决它。请再次帮助我!非常感谢
答案 0 :(得分:0)
您需要安装autoconf
软件包:
sudo apt-get install autoconf
答案 1 :(得分:0)
您缺少 libtool
库。此命令应该可以解决您的问题。
sudo apt-get update
sudo apt-get install libtool