安卓導(dǎo)入flutter module 報(bào)錯(cuò),可build三椿,無法運(yùn)行
Execution failed for task ':app:mergeDebugJavaResource'.
> Could not resolve all files for configuration ':app:debugRuntimeClasspath'.
> Could not find flutter-1.0-debug.jar (com.example.my_flutter:flutter:1.0).
Searched in the following locations:
file:/xxx/MyApplication/app/libs/com/example/my_flutter/flutter/1.0/flutter-1.0-debug.jar
Possible solution:
- Declare repository providing the artifact, see the documentation at https://docs.gradle.org/current/userguide/declaring_repositories.html
flutter module 執(zhí)行 flutter build aar缺菌,如下圖
按照控制臺(tái)信息進(jìn)行配置后,發(fā)現(xiàn)報(bào)錯(cuò)
解決搜锰,修改如下
這里也標(biāo)注一下男翰,關(guān)于arr配置路徑,
allprojects{
repositories {
maven{
url './libs'//將arr的目錄纽乱,從repo文件下所有文件拷貝到項(xiàng)目libs下
}
// maven {
// url './../../my_flutter/build/host/outputs/repo'//相對(duì)路徑蛾绎,可以正常運(yùn)行
// }
maven {
url "https://mirrors.cloud.tencent.com/flutter/download.flutter.io"http://鏡像
}
}
}