I have already managed to build many versions of this same project and put it in the Google Play Store, but I am no longer able to do so with the new versions of the expo SDK etc.Currently, my dependency versions are these:
buildscript {ext {buildToolsVersion = findProperty('android.buildToolsVersion') ?: '34.0.0'minSdkVersion = Integer.parseInt(findProperty('android.minSdkVersion') ?: '21')compileSdkVersion = Integer.parseInt(findProperty('android.compileSdkVersion') ?: '34')targetSdkVersion = Integer.parseInt(findProperty('android.targetSdkVersion') ?: '34')if (findProperty('android.kotlinVersion')) {kotlinVersion = findProperty('android.kotlinVersion')}frescoVersion = findProperty('expo.frescoVersion') ?: '2.5.0'// We use NDK 23 which has both M1 support and is the side-by-side NDK version from AGP.ndkVersion = "23.1.7779620"}repositories {google()mavenCentral()}dependencies {classpath('com.android.tools.build:gradle:7.4.0')classpath('com.facebook.react:react-native-gradle-plugin')classpath('org.jetbrains.kotlin:kotlin-gradle-plugin:1.8.10')}}
My Java JDK version is 21.0.2.
And my gradle-wrapper.properties is this:
distributionBase=GRADLE_USER_HOMEdistributionPath=wrapper/distsdistributionUrl=https://services.gradle.org/distributions/gradle-8.5-bin.zipzipStoreBase=GRADLE_USER_HOMEzipStorePath=wrapper/dists
And this is the error in the terminal:
What went wrong:Execution failed for task ':react-native-community_datetimepicker:compileDebugJavaWithJavac'.> Could not resolve all files for configuration ':react-native-community_datetimepicker:androidJdkImage'.> Failed to transform core-for-system-modules.jar to match attributes {artifactType=\_internal_android_jdk_image, org.gradle.libraryele`your text`ments=jar, org.gradle.usage=java-runtime}.> Execution failed for JdkImageTransform: \\Local\\Android\\Sdk\\platforms\\android-34\\core-for-system-modules.jar.> Error while executing process C:\\Program Files\\Java\\jdk-21\\bin\\jlink.exe with arguments {--module-path .gradle\\caches\\transforms-3\\7b8607e7136a0bf35e15dfad6551fa85\\transformed\\output\\temp\\jmod --add-modules java.base --output .gradle\\caches\\transforms-3\\7b8607e7136a0bf35e15dfad6551fa85\\transformed\\output\\jdkImage --disable-plugin system-modules}
I tried switching versions of kotlin-gradle-plugin, android.tools.build:gradle and distributionUrl=https://services.gradle.org/distributions/gradle-8.5-bin.zipI just tried to downgrade Java to 17 once and even more confusing errors appeared.
I tried switching between some other versions of the plugins and nothing.I changed the Java JDK version to 17 and then back.