在Android手机中打开浏览器时出错

Error while opening browser in android phone

提问人:Apoorv Gupta 提问时间:10/30/2023 更新时间:10/30/2023 访问量:21

问:

我正在尝试在android手机中打开浏览器,我正在使用浏览器的调试版本。 我正在使用命令安装应用程序的APK

./src/<directory>/<filename_apk> run

它已成功安装在模拟器和Android设备上。但是当我打开它时,并没有打开。

为了找到错误的原因,我确实记录了。

展示:

E AndroidRuntime: FATAL EXCEPTION: main E Android运行时: 进程: <package_name>, PID: XXXXX E AndroidRuntime:java.lang.RuntimeException:无法启动活动 ComponentInfo{<package_name>.firstrun.WelcomeOnboardingActivity}: java.lang.RuntimeException:以 64 位模式启动需要 64 位本机库。如果设备仅是 64 位,请参阅此处的替代方法:https://crbug.com/1303857#c7

我以为我的代码中没有 64 位库。

所以我运行了命令:

adb install --abi arm64-v8a .<directory/APK Name>.apk

输出 : SUCCESS

但仍然没有打开。

其他一些错误是:

W ActivityThread:应用程序<package_name>可以在端口上调试。 10-30 12:13:18.431 W ziparchive:无法打开“/data/app/~~<目录/文件名>/base.dm”:没有这样的文件或目录

在日志中有一些内容:

AndroidRuntime:原因:java.lang.RuntimeException:以 64 位模式启动需要 64 位本机库。如果设备仅是 64 位,请参阅此处的替代方法:https://crbug.com/1303857#c7

那么错误是什么,在上面的日志下面有一些类和函数。

private void ensureLibraryCanBeLoadedIn64Bit() { // Fail here before loading libmonochrome.so on 64-bit platforms, otherwise the failing // native stacktrace will not make it obvious that this is a bitness issue. See this bug // for context: https://crbug.com/1303857 While non-component builds has only one library, // monochrome may not be the first in the list for component builds. for (String libraryName : NativeLibraries.LIBRARIES) { if (libraryName.equals("monochrome") || libraryName.equals("monochrome.cr")) { throw new RuntimeException( "Starting in 64-bit mode requires the 64-bit native library. If the " + "device is 64-bit only, see alternatives here: " + "https://crbug.com/1303857#c7."); } } }

此函数负责它引发错误的原因。我以铬为基。

我尝试做日志,并通过互联网搜索并使用LLM。

安卓 Linux 谷歌 安卓浏览器

评论


答: 暂无答案