没有这样的文件或目录 buildozer 调试运行
Posted
技术标签:
【中文标题】没有这样的文件或目录 buildozer 调试运行【英文标题】:No such file or directory buildozer debug run 【发布时间】:2021-11-18 14:27:03 【问题描述】:我在尝试使用 buildozer 编译我的 kivy 应用程序时遇到错误。它告诉我没有这样的文件或目录。当我去检查目录时,它是Reminder__armeabi-v7a/project.properties
,但它似乎需要Reminder system__armeabi-v7a/project.properties
的目录。
我不知道是否建议重命名目录,因为我没有创建目录。它是在构建过程中自动创建的。此外,当我尝试将文件夹重命名为“Reminder system__armeabi-v7a/project.properties”时,我收到错误消息“toolchain.py: error unrecognized argument system system”,所以我恢复了所做的更改,我正在寻找另一个解决方案。
我的buildozer.spec
文件如下所示:
[app]
title = My Reminder System
package.name = Reminder system
package.domain = org.test
source.dir = .
source.include_exts = py,png,jpg,kv,atlas,txt,json
version = 0.1
requirements = python3,kivy,DateTime,SpeechRecognition
orientation = portrait
osx.python_version = 3
osx.kivy_version = 1.9.1
fullscreen = 0
android.logcat_filters = *:S python:D
android.arch = armeabi-v7a
android.allow_backup = True
ios.kivy_ios_url = https://github.com/kivy/kivy-ios
ios.kivy_ios_branch = master
ios.ios_deploy_url = https://github.com/phonegap/ios-deploy
ios.ios_deploy_branch = 1.10.0
ios.codesign.allowed = false
[buildozer]
log_level = 2
warn_on_root = 1
这是包含错误消息的 buildozer 输出:
/home/umarfarouk/Reminder_system/implementation/.buildozer/android/platform/build-armeabi-v7a/dists/Reminder__armeabi-v7a/libs/armeabi-v7a/libpython3.8.so
[INFO]: Stripping libraries in private dir
[INFO]: Frying eggs in /home/umarfarouk/Reminder_system/implementation/.buildozer/android/platform/build-armeabi-v7a/dists/Reminder__armeabi-v7a/_python_bundle/_python_bundle/site-packages
[INFO]: Copying in SDL2 .java files from: /home/umarfarouk/Reminder_system/implementation/.buildozer/android/platform/build-armeabi-v7a/build/bootstrap_builds/sdl2/jni/SDL/android-project/app/src/main/java/org/libsdl/app
[INFO]: -> directory context /home/umarfarouk/Reminder_system/implementation/.buildozer/android/platform/build-armeabi-v7a/dists/Reminder__armeabi-v7a
[INFO]: Saving distribution info
[INFO]: <- directory context /home/umarfarouk/Reminder_system/implementation/.buildozer/android/platform/python-for-android
[INFO]: # Your distribution was created successfully, exiting.
[INFO]: Dist can be found at (for now) /home/umarfarouk/Reminder_system/implementation/.buildozer/android/platform/build-armeabi-v7a/dists/Reminder__armeabi-v7a
# Build the application #8
# Copy application source from /home/umarfarouk/Reminder_system/implementation
# Create directory /home/umarfarouk/Reminder_system/implementation/.buildozer/android/app
# Copy /home/umarfarouk/Reminder_system/implementation/user_data.json
# Copy /home/umarfarouk/Reminder_system/implementation/home2.kv
# Copy /home/umarfarouk/Reminder_system/implementation/lab2.py
# Copy /home/umarfarouk/Reminder_system/implementation/bin.txt
# Copy /home/umarfarouk/Reminder_system/implementation/login.Kv
# Copy /home/umarfarouk/Reminder_system/implementation/user_menu.kv
# Copy /home/umarfarouk/Reminder_system/implementation/home.kv
# Copy /home/umarfarouk/Reminder_system/implementation/calendar.kv
# Copy /home/umarfarouk/Reminder_system/implementation/lab.py
# Copy /home/umarfarouk/Reminder_system/implementation/lab3.kv
# Copy /home/umarfarouk/Reminder_system/implementation/voice.py
# Copy /home/umarfarouk/Reminder_system/implementation/lab3.py
# Copy /home/umarfarouk/Reminder_system/implementation/assignment.kv
# Copy /home/umarfarouk/Reminder_system/implementation/Courses.kv
# Copy /home/umarfarouk/Reminder_system/implementation/lab.kv
# Copy /home/umarfarouk/Reminder_system/implementation/reg.kv
# Copy /home/umarfarouk/Reminder_system/implementation/studio.py
# Copy /home/umarfarouk/Reminder_system/implementation/inspirational_quotes.txt
# Copy /home/umarfarouk/Reminder_system/implementation/popup.kv
# Copy /home/umarfarouk/Reminder_system/implementation/sign_up.kv
# Copy /home/umarfarouk/Reminder_system/implementation/new_login.kv
# Copy /home/umarfarouk/Reminder_system/implementation/style1.kv
# Copy /home/umarfarouk/Reminder_system/implementation/scheduler.kv
# Copy /home/umarfarouk/Reminder_system/implementation/advan.txt
# Copy /home/umarfarouk/Reminder_system/implementation/home.py
# Copy /home/umarfarouk/Reminder_system/implementation/Ttable.kv
# Copy /home/umarfarouk/Reminder_system/implementation/Advantages.txt
# Create directory /home/umarfarouk/Reminder_system/implementation/.buildozer/android/app/images
# Copy /home/umarfarouk/Reminder_system/implementation/images/11.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/16.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/9.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/4.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/10.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/15.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/s6.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/convert5.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/14.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/s4.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/convert4.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/6.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/12.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/convert2.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/convert6.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/19.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/8.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/7.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/13.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/convert3.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/2.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/18.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/convert1.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/20.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/5.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/3.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/1.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/17.jpg
# Copy /home/umarfarouk/Reminder_system/implementation/images/s5.jpg
# Package the application
Traceback (most recent call last):
File "/usr/local/bin/buildozer", line 11, in <module>
load_entry_point('buildozer==1.2.0.dev0', 'console_scripts', 'buildozer')()
File "/usr/local/lib/python3.8/dist-packages/buildozer-1.2.0.dev0-py3.8.egg/buildozer/scripts/client.py", line 13, in main
Buildozer().run_command(sys.argv[1:])
File "/usr/local/lib/python3.8/dist-packages/buildozer-1.2.0.dev0-py3.8.egg/buildozer/__init__.py", line 1020, in run_command
self.target.run_commands(args)
File "/usr/local/lib/python3.8/dist-packages/buildozer-1.2.0.dev0-py3.8.egg/buildozer/target.py", line 92, in run_commands
func(args)
File "/usr/local/lib/python3.8/dist-packages/buildozer-1.2.0.dev0-py3.8.egg/buildozer/target.py", line 104, in cmd_debug
self.buildozer.build()
File "/usr/local/lib/python3.8/dist-packages/buildozer-1.2.0.dev0-py3.8.egg/buildozer/__init__.py", line 205, in build
self.target.build_package()
File "/usr/local/lib/python3.8/dist-packages/buildozer-1.2.0.dev0-py3.8.egg/buildozer/targets/android.py", line 1076, in build_package
self._update_libraries_references(dist_dir)
File "/usr/local/lib/python3.8/dist-packages/buildozer-1.2.0.dev0-py3.8.egg/buildozer/targets/android.py", line 1349, in _update_libraries_references
with io.open(project_fn, 'w', encoding='utf-8') as fd:
FileNotFoundError: [Errno 2] No such file or directory: '/home/umarfarouk/Reminder_system/implementation/.buildozer/android/platform/build-armeabi-v7a/dists/Reminder system__armeabi-v7a/project.properties'
umarfarouk@umarfarouk-VirtualBox:~/Reminder_system/implementation$
为什么我会收到此错误消息,我该如何解决?
【问题讨论】:
嗨 V24。我冒昧地重写了你的帖子,因为它真的很难阅读。请阅读How do I write a good answer? 了解如何改进您的问题。我重写了您的介绍以使其更具可读性,并修复和减少了您的配置文件(buildozer.spec)。它缺少[app]
标头,并且所有 cmets 都不是必需的。这让这个问题变得非常冗长。我花了相当多的努力,我可以想象大多数人不会这样做,而是投反对票。所以我希望这些提示对你有所帮助。
【参考方案1】:
我不熟悉 buildozer,但是您的错误消息中的路径包含一个可疑的空格(不幸的是,许多工具仍然无法使用路径中的空格...)。它似乎来自buildozer.spec
中的package.name
变量,即“提醒系统”。
简单地重命名不是您自己创建的目录通常是个坏主意。很高兴您恢复了该操作。
documentation of buildozer.spec
声明如下:
包名是一个单词,只有 ASCII 字符和/或数字。它不应包含任何特殊字符。例如,如果您的应用程序名为 Flat Jewels,则包名称可以是 flatjewels。
所以我猜想将该行更改为:
package.name = ReminderSystem
应该能解决问题。
【讨论】:
以上是关于没有这样的文件或目录 buildozer 调试运行的主要内容,如果未能解决你的问题,请参考以下文章
无法打开共享对象文件:没有这样的文件或目录;在 Eclipse 中运行或调试
反应本机调试器:“错误:ENOENT:没有这样的文件或目录”
《Buildozer打包实战指南》第四节 正式打包一个apk文件
Kivy Buildozer:.so lib 文件缺少调试符号