I followed all the setups mentioned in the docs, tried to build/run, and got the following issue. I have tried all the mentioned things my AI model, google and stack overflow But I still have this issue. Please anyone help me to solve this:
wabisabi@wabisabi:~/Desktop/AnyDoc/android$ flutter run
Changing current working directory to: /home/wabisabi/Desktop/AnyDoc
Launching lib/main.dart on sdk gphone64 x86 64 in debug mode...
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':receive_sharing_intent:compileDebugKotlin'.
> 'compileDebugJavaWithJavac' task (current target is 1.8) and 'compileDebugKotlin' task (current target is 17) jvm target compatibility should be set to the same Java version.
Consider using JVM toolchain: https://kotl.in/gradle/jvm/toolchain
* 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.
> Get more help at https://help.gradle.org.
BUILD FAILED in 19s
Running Gradle task 'assembleDebug'... 20.0s
Error: Gradle task assembleDebug failed with exit code 1
wabisabi@wabisabi:~/Desktop/AnyDoc/android$
Updated:
I slove the issue By Downloading the JDK version 17 and updating the following file:
android/app/build.gradleandroid/gradle/wrapper/gradle-wrapper.propertiesandroid/build.gradle
I followed all the setups mentioned in the docs, tried to build/run, and got the following issue. I have tried all the mentioned things my AI model, google and stack overflow But I still have this issue. Please anyone help me to solve this: