From 7dddc9854959e699a1b12aced03368c9f30cdb8a Mon Sep 17 00:00:00 2001 From: Markus Amshove Date: Sun, 16 Oct 2022 13:24:23 +0200 Subject: [PATCH] Fix Java version to run on --- build.gradle | 4 ++++ common/build.gradle | 3 +++ 2 files changed, 7 insertions(+) diff --git a/build.gradle b/build.gradle index 696256b..b3907b8 100644 --- a/build.gradle +++ b/build.gradle @@ -68,6 +68,10 @@ subprojects { withSourcesJar() } + def isAndroid = project.rootProject.hasProperty("ANDROID") + sourceCompatibility = isAndroid ? 1.6 : 1.8 + targetCompatibility = isAndroid ? 1.6 : 1.8 + publishing { repositories { maven { diff --git a/common/build.gradle b/common/build.gradle index 494a268..7849844 100644 --- a/common/build.gradle +++ b/common/build.gradle @@ -10,6 +10,9 @@ dependencies { configurePublishing() +sourceCompatibility = 1.6 +targetCompatibility = 1.6 + compileKotlinCommon { kotlinOptions { freeCompilerArgs += [