简体   繁体   English

Firebase Crashlytics NDK 未剥离文件

[英]Firebase Crashlytics NDK unstripped files

I have an SDK that uses C++ code.我有一个使用 C++ 代码的 SDK。 The SDK exports 4 different modules in a maven repo that I publish on either a local maven repo or on GitHub packages. SDK 在我在本地 maven 回购或 GitHub 包上发布的 maven 回购中导出 4 个不同的模块。 The apps that consume the SDK should be able to use Firebase Crashlytics and get reports of crashes in the native code as well.使用 SDK 的应用程序应该能够使用 Firebase Crashlytics 并在本机代码中获取崩溃报告。

The first problem I have is that I need to provide to the Firebase plugin the folders unstrippedNativeLibsDir and strippedNativeLibsDir :我遇到的第一个问题是我需要向 Firebase 插件提供文件夹unstrippedNativeLibsDirstrippedNativeLibsDir

firebaseCrashlytics {
    nativeSymbolUploadEnabled true
    unstrippedNativeLibsDir "???"
    strippedNativeLibsDir "???"
}

If I go to the project where I build the SDK I can see: build/intermediates/merged_native_libs/release and build/intermediates/stripped_native_libs .如果我将 go 转到我构建 SDK 的项目,我可以看到: build/intermediates/merged_native_libs/releasebuild/intermediates/stripped_native_libs

Are these the unstripped and stripped folder respectively?这些分别是未剥离和剥离的文件夹吗?

Is there any documentation about what exactly those folders are supposed to contain?是否有关于这些文件夹究竟应该包含什么的文档?

Anyway if I configure the app firebaseCrashlytics to point to these folders I still need to fix another issue.无论如何,如果我将应用程序firebaseCrashlytics配置为指向这些文件夹,我仍然需要解决另一个问题。 I get:我得到:

Crashlytics could not find NDK build tasks on which to depend. Crashlytics 找不到要依赖的 NDK 构建任务。 You many need to manually enforce task dependencies许多人需要手动强制执行任务依赖性

It looks like since I'm building the libs that use the NDK in another project, then the Firebase plugin does not work.看起来因为我在另一个项目中构建使用 NDK 的库,所以 Firebase 插件不起作用。

What am I supposed to do?我应该做些什么? Is it possible to get the Crashlytics NDK working even if I build the libraries independently with a separate project?即使我使用单独的项目独立构建库,是否有可能使 Crashlytics NDK 正常工作?

The only way I made it work was to build the libraries along with the app.我让它工作的唯一方法是与应用程序一起构建库。 The libraries were in separate repos anyway but I included them as sub-repositories in the app.无论如何,这些库都在单独的存储库中,但我将它们作为子存储库包含在应用程序中。 In this way, you solve the issue of not finding NDK build tasks on which to depend .这样,您就解决了找不到NDK build tasks on which to depend的问题。

I know this is not the answer though我知道这不是答案

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM