When packagind the project for quest2,its throwing this error! UATHelper: Packaging (Android (ASTC)): * What went wrong: UATHelper: Packaging (Android (ASTC)): A problem was found with the configuration of task ':app:compileDebugAidl' (type 'AidlCompile'). UATHelper: Packaging (Android (ASTC)): > File 'C:\Users\czars\AppData\Local\Android\Sdk\platforms\android-30\framework.aidl' specified for property 'aidlFrameworkProvider' does not exist. UATHelper: Packaging (Android (ASTC)): 1 actionable task: 1 executed UATHelper: Packaging (Android (ASTC)): * Try: UATHelper: Packaging (Android (ASTC)): 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. UATHelper: Packaging (Android (ASTC)): * Get more help at https://help.gradle.org/ UATHelper: Packaging (Android (ASTC)): BUILD FAILED in 7s UATHelper: Packaging (Android (ASTC)): ERROR: cmd.exe failed with args /c "C:\Users\czars\ue projects\gradlebatch\Intermediate\Android\arm64\gradle\rungradle.bat" :app:assembleDebug UATHelper: Packaging (Android (ASTC)): (see C:\Users\czars\AppData\Roaming\Unreal Engine\AutomationTool\Logs\C+Program+Files+Epic+Games+UE_5.0\Log.txt for full exception trace) UATHelper: Packaging (Android (ASTC)): AutomationTool executed for 0h 0m 36s UATHelper: Packaging (Android (ASTC)): AutomationTool exiting with ExitCode=1 (Error_Unknown) UATHelper: Packaging (Android (ASTC)): Updating environment variables set by a Turnkey sub-process UATHelper: Packaging (Android (ASTC)): The system cannot find the path specified. UATHelper: Packaging (Android (ASTC)): The system cannot find the path specified. PackagingResults: Error: cmd.exe failed with args /c "C:\Users\czars\ue projects\gradlebatch\Intermediate\Android\arm64\gradle\rungradle.bat" :app:assembleDebug.
The error raises when Android sdk, API level, sdk tools , gradle plugin versions aren't compatible. I'm building a project for metaquest-2 with android API level-29. Android studio Version-4.0 For this :
// Top-level build file where you can add configuration options common to all sub-projects/modules.
plugins {
id 'com.android.application' version '6.5.1' apply false
id 'com.android.library' version '6.5.1' apply false
id 'org.jetbrains.kotlin.android' version '1.7.10' apply false }
gradle.build(Module:My_Application.app):
plugins {
id 'com.android.application'
id 'org.jetbrains.kotlin.android'
}
android {
namespace 'com.example.myapplication'
compileSdk 29
defaultConfig {
applicationId "com.example.myapplication"
minSdk 23
//noinspection ExpiredTargetSdkVersion
targetSdk 29
versionCode 1
versionName "1.0"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
kotlinOptions {
jvmTarget = '1.8'
}
buildToolsVersion '29.0.3'
ndkVersion '21.4.7075529'
}
dependencies {
implementation 'androidx.core:core-ktx:1.9.0'
implementation 'androidx.appcompat:appcompat:1.5.1'
implementation 'com.google.android.material:material:1.6.1'
//noinspection GradleDependency
implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
testImplementation 'junit:junit:4.13.2'
androidTestImplementation 'androidx.test.ext:junit:1.1.3'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0'
}