4

hi im getting this error while putting a native code to flutter native side . seems like a java error but i tried several methods to clear out the error but couldn't do it . now i'm getting this error

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:compileDevDebugJavaWithJavac'.
> Could not resolve all files for configuration ':app:androidJdkImage'.
   > Failed to transform core-for-system-modules.jar to match attributes {artifactType=_internal_android_jdk_image, org.gradle.libraryelements=jar, org.gradle.usage=java-runtime}.
      > Execution failed for JdkImageTransform: C:\Users\yasmitha_local\AppData\Local\Android\Sdk\platforms\android-33\core-for-system-modules.jar.
         > jlink executable C:\Program Files\Java\jdk1.8.0_301\bin\jlink.exe does not exist.
android {
    compileSdkVersion 33
    ndkVersion flutter.ndkVersion

    compileOptions {
        sourceCompatibility JavaVersion.VERSION_11
        targetCompatibility JavaVersion.VERSION_11
    }

buildscript {
    ext.kotlin_version = '1.6.10'
    repositories {
        google()
        mavenCentral()
    }

    dependencies {
        classpath 'com.google.gms:google-services:4.3.13'
        classpath 'com.android.tools.build:gradle:7.1.1'
        classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
    }
}

<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    package="com.epic.digiface">

    <application
        tools:replace="android:label"
        android:name="${applicationName}"
        android:label="digiface"
        android:icon="@mipmap/ic_launcher">
        <activity
            android:name=".MainActivity"
            android:exported="false"
            android:launchMode="singleTop"
            android:theme="@style/LaunchTheme"
            
Andrej Istomin
  • 2,527
  • 2
  • 15
  • 22

0 Answers0