Android 北极狐的 InvocationTargetException |2020.3.1 苹果 M1 芯片上的 arm64 [英] InvocationTargetException with Android Arctic Fox | 2020.3.1 arm64 on M1 Apple silicon

查看:35
本文介绍了Android 北极狐的 InvocationTargetException |2020.3.1 苹果 M1 芯片上的 arm64的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在我的 M1 Apple Silicon 上使用 kapt(例如 Room)构建我的 Android 项目期间

During a build of my Android project on my M1 Apple Silicon using kapt (eg Room)

Android Studio Arctic Fox | 2020.3.1 Beta 1 arm64
..
Android Studio Arctic Fox | 2020.3.1 Beta 5 arm64
Android Studio Bumblebee | 2021.1.1 Canary 2 aarch64

Android Studio Arctic Fox | 2020.3.1 Beta 5
Build #AI-203.7717.56.2031.7360992, built on May 14, 2021
Runtime version: 11.0.10+0-b96-7249189 aarch64
VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o.
macOS 11.4

我遇到了

Execution failed for task ':FFTSpectrumLib:kaptDebugKotlin'.
> A failure occurred while executing org.jetbrains.kotlin.gradle.internal.KaptWithoutKotlincTask$KaptExecutionWorkAction
   > java.lang.reflect.InvocationTargetException (no error message)

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

我不知道如何让它与快速的 aarch64 一起工作!

I've no clue how to make it work with fast aarch64 !

使用 x86 就可以了

Android Studio Arctic Fox | 2020.3.1 Beta 1 x86

推荐答案

根本原因是 Room 2.3.0这个 https://github.com/xerial/sqlite-jdbc/issues/450 指出我的解决方案

The root cause was Room 2.3.0 This https://github.com/xerial/sqlite-jdbc/issues/450 pointed me to the solution

添加

kapt "org.xerial:sqlite-jdbc:3.34.0"

它包括这个 https://github.com/xerial/sqlite-jdbc/releases/tag/3.32.3.3

只需使用 Room 2.4.0-alpha03

这篇关于Android 北极狐的 InvocationTargetException |2020.3.1 苹果 M1 芯片上的 arm64的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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