Kivy Buildozer:.so lib文件缺少调试符号 [英] Kivy Buildozer: .so lib files missing debug symbols

查看:360
本文介绍了Kivy Buildozer:.so lib文件缺少调试符号的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

.so lib文件缺少调试符号

.so lib files missing debug symbols

因此,我尝试使bin/debug.apk在Buildozer VM中工作,但是加载adb并通过USB连接Android设备时出现了问题,因此我将bin/debug.apk导出到了桌面以进行调试它在Android Studio中.但是,在第一步中,它抛出一个错误,要求我用具有调试符号的相同库替换.so库.

So I tried getting my bin/debug.apk to work in the Buildozer VM, but there was a problem with loading adb and attaching my Android device via USB, so I exported my bin/debug.apk to my desktop to debug it in Android Studio. However, in its first steps, it throws an error that asks me to replace the .so libraries with identical ones that have debug symbols.

.so lib文件缺少调试符号

在buildozer android调试阶段,这些东西是否藏在Buildozer VM中的任何地方?

Are these stashed anywhere in the Buildozer VM during the buildozer android debug phase?

有没有办法获取带有符号的库,或者解决没有在Android Studio或Buildozer VM上使用它们的问题?

Is there a way to either get the libs with the symbols or work around not having them on either Android Studio or the Buildozer VM?

推荐答案

附加本机调试符号

如果您的APK包含不包含调试符号的本机库(.so文件),则IDE在消息窗口中向您显示警告.如果不附加可调试的本机库,则无法调试APK的本机代码或使用断点.

Attach native debug symbols

If your APK includes native libraries (.so files) that do not include debug symbols, the IDE shows you a warning in the Messages window. You cannot debug the APK’s native code or use breakpoints without attaching debuggable native libraries.

要附加可调试的本机库,请按照下列步骤操作:

To attach debuggable native libraries, proceed as follows:

  1. 如果您尚未这样做,请确保下载NDK和工具.
  2. Project 窗口的 cpp 目录下(仅当您选择了 Android 视图时才可见,如下图所示),双击不包含调试符号的本机库文件.编辑器会显示一个表格,其中包含您的APK支持的所有ABI.
  3. 点击编辑器窗口右上角的添加.
  4. 导航到包含要附加的可调试本机库的目录,然后单击 确定.
  1. If you have not already done so, make sure to download the NDK and tools.
  2. Under the cpp directory in the Project window (visible only if you have selected the Android view, as shown in below figure), double-click a native library file that doesn't include debug symbols. The editor shows a table of all the ABIs your APK supports.
  3. Click Add at the top right corner of the editor window.
  4. Navigate to the directory that includes the debuggable native libraries you want to attach and click OK.

如果APK和可调试的本机库是使用其他工作站构建的,则还需要按照以下步骤指定本地调试符号的路径:

If the APK and debuggable native libraries were built using a different workstation, you need to also specify paths to local debug symbols by following these steps:

    通过编辑编辑器窗口的 Path Mappings 部分的 Local Paths 列下的字段,将
  1. 添加到缺少的调试符号的本地路径,如下图所示. 在大多数情况下,您只需要提供根文件夹的路径,Android Studio就会自动检查子目录以映射其他源. IDE还会自动将远程NDK的路径映射到本地NDK下载.
  2. 在编辑器窗口的路径映射部分中点击应用更改.
  1. Add local paths to missing debug symbols by editing the field under the Local Paths column in the Path Mappings section of the editor window, as shown in below figure. In most cases, you need only provide the path to a root folder, and Android Studio automatically inspects subdirectories to map additional sources. The IDE also automatically maps paths to a remote NDK to your local NDK download.
  2. Click Apply Changes in the Path Mappings section of the editor window.

您现在应该在 Project 窗口中看到本机源文件.打开这些本机文件以添加断点,然后像往常一样调试您的应用.您还可以通过在编辑器窗口的路径映射部分中单击清除来删除映射.

You should now see the native source files in the Project window. Open those native files to add breakpoints and debug your app as you normally would. You can also remove the mappings by clicking Clear in the Path Mappings section of the editor window .

已知问题:在将调试符号附加到APK时,必须使用同一工作站或构建服务器来构建APK和可调试的.so文件.

Known issue: When attaching debug symbols to an APK, both the APK and debuggable .sofiles must be built using the same workstation or build server.

这篇关于Kivy Buildozer:.so lib文件缺少调试符号的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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