當我在Android Studio中打開ARSimpleProj並嘗試更新版本的Gradle我得到這個消息:的ARToolKit ARSimpleProj錯誤
Failed to update the version of the Android Gradle plugin.
Please click 'OK' to perform a textual search and then update the build files manually.
在此之後,我得到這個錯誤:
Error:(58, 0) Gradle DSL method not found: 'android()'
Possible causes:
* The project 'ARSimpleProj' may be using a version of the Android Gradle plug-in that does not contain the method (e.g. 'testCompile' was added in 1.1.0). Fix plugin version and sync project
* The project 'ARSimpleProj' may be using a version of Gradle that does not contain the method. Open Gradle wrapper file
* The build file may be missing a Gradle plugin. Apply Gradle plugin.
我嘗試從頂級build.gradle
文件中刪除android->buildToolsVersion
和依賴關係標記(如AS_Migration
文檔中所示),但仍然無效。