[#330] Use KSP for annotation processing
This resolves issues with included builds
This commit is contained in:
parent
8e1e0e866f
commit
eb728fe3d8
|
@ -234,8 +234,6 @@ Publishing instructions for maintainers of this repository can be found in [PUBL
|
||||||
[Back to contents](#contents)
|
[Back to contents](#contents)
|
||||||
|
|
||||||
# Known Issues
|
# Known Issues
|
||||||
1. [#330](https://github.com/zcash/zcash-android-wallet-sdk/issues/330) The SDK will fail to build on Java 16 or later. It is recommended that at least Java 11 is installed. If a newer JDK is needed, Java 15 can also be installed.
|
1. `ktlintFormat` may fail on Java 16 or greater. As a workaround, the task is run under Java 11. This requires that JDK 11 be installed, even if a newer JDK is also installed. While this is configured to use the Java toolchain API, [toolchain support for Java 11 does not work on Apple Silicon](https://github.com/gradle/gradle/issues/19140)
|
||||||
1. Some JDK distributions don't offer older versions for Apple Silicon. [Azul Zulu](https://www.azul.com/downloads/?os=macos&architecture=arm-64-bit&package=jdk) does offer JDK 11 and JDK 15 for Apple Silicon, which should be compatible with our builds.
|
|
||||||
1. `ktlintFormat` may fail on Java 16 or greater. As a workaround, the task is run under Java 11. This requires that JDK 11 be installed, even if a newer JDK is also installed. While this is configured to use the Java toolchain API, [toolchain support for Java 11 does not work on Apple Silicon](https://github.com/gradle/gradle/issues/19140)
|
|
||||||
1. During builds, a warning will be printed that says "Unable to detect AGP versions for included builds. All projects in the build should use the same AGP version." This can be safely ignored. The version under build-conventions is the same as the version used elsewhere in the application.
|
1. During builds, a warning will be printed that says "Unable to detect AGP versions for included builds. All projects in the build should use the same AGP version." This can be safely ignored. The version under build-conventions is the same as the version used elsewhere in the application.
|
||||||
1. Android Studio will warn about the Gradle checksum. This is a [known issue](https://github.com/gradle/gradle/issues/9361) and can be safely ignored.
|
1. Android Studio will warn about the Gradle checksum. This is a [known issue](https://github.com/gradle/gradle/issues/9361) and can be safely ignored.
|
||||||
|
|
|
@ -4,6 +4,7 @@ buildscript {
|
||||||
gradlePluginPortal()
|
gradlePluginPortal()
|
||||||
}
|
}
|
||||||
dependencies {
|
dependencies {
|
||||||
|
classpath(kotlin("gradle-plugin", version = libs.versions.kotlin.get()))
|
||||||
classpath(libs.gradle.plugin.android)
|
classpath(libs.gradle.plugin.android)
|
||||||
classpath(libs.gradle.plugin.rust)
|
classpath(libs.gradle.plugin.rust)
|
||||||
classpath(libs.gradle.plugin.publish)
|
classpath(libs.gradle.plugin.publish)
|
||||||
|
|
|
@ -65,6 +65,7 @@ DETEKT_VERSION=1.18.1
|
||||||
DOKKA_VERSION=1.6.10
|
DOKKA_VERSION=1.6.10
|
||||||
GRADLE_VERSIONS_PLUGIN_VERSION=0.38.0
|
GRADLE_VERSIONS_PLUGIN_VERSION=0.38.0
|
||||||
KTLINT_VERSION=0.43.0
|
KTLINT_VERSION=0.43.0
|
||||||
|
KSP_VERSION=1.6.10-1.0.2
|
||||||
MAVEN_PUBLISH_GRADLE_PLUGIN=0.18.0
|
MAVEN_PUBLISH_GRADLE_PLUGIN=0.18.0
|
||||||
OWASP_DEPENDENCY_CHECK_VERSION=6.5.0.1
|
OWASP_DEPENDENCY_CHECK_VERSION=6.5.0.1
|
||||||
PROTOBUF_GRADLE_PLUGIN_VERSION=0.8.18
|
PROTOBUF_GRADLE_PLUGIN_VERSION=0.8.18
|
||||||
|
|
|
@ -9,7 +9,7 @@ plugins {
|
||||||
id("com.android.library")
|
id("com.android.library")
|
||||||
id("zcash.android-build-conventions")
|
id("zcash.android-build-conventions")
|
||||||
kotlin("android")
|
kotlin("android")
|
||||||
kotlin("kapt")
|
id("com.google.devtools.ksp")
|
||||||
id("org.jetbrains.kotlin.plugin.allopen")
|
id("org.jetbrains.kotlin.plugin.allopen")
|
||||||
id("org.jetbrains.dokka")
|
id("org.jetbrains.dokka")
|
||||||
id("com.google.protobuf")
|
id("com.google.protobuf")
|
||||||
|
@ -170,7 +170,7 @@ dependencies {
|
||||||
// Architecture Components: Room
|
// Architecture Components: Room
|
||||||
implementation(libs.androidx.room.core)
|
implementation(libs.androidx.room.core)
|
||||||
implementation(libs.androidx.paging)
|
implementation(libs.androidx.paging)
|
||||||
kapt(libs.androidx.room.compiler)
|
ksp(libs.androidx.room.compiler)
|
||||||
|
|
||||||
// Kotlin
|
// Kotlin
|
||||||
implementation(libs.kotlin.stdlib)
|
implementation(libs.kotlin.stdlib)
|
||||||
|
|
|
@ -12,10 +12,12 @@ pluginManagement {
|
||||||
val dokkaVersion = extra["DOKKA_VERSION"].toString()
|
val dokkaVersion = extra["DOKKA_VERSION"].toString()
|
||||||
val gradleVersionsPluginVersion = extra["GRADLE_VERSIONS_PLUGIN_VERSION"].toString()
|
val gradleVersionsPluginVersion = extra["GRADLE_VERSIONS_PLUGIN_VERSION"].toString()
|
||||||
val kotlinVersion = extra["KOTLIN_VERSION"].toString()
|
val kotlinVersion = extra["KOTLIN_VERSION"].toString()
|
||||||
|
val kspVersion = extra["KSP_VERSION"].toString()
|
||||||
val owaspVersion = extra["OWASP_DEPENDENCY_CHECK_VERSION"].toString()
|
val owaspVersion = extra["OWASP_DEPENDENCY_CHECK_VERSION"].toString()
|
||||||
val protobufVersion = extra["PROTOBUF_GRADLE_PLUGIN_VERSION"].toString()
|
val protobufVersion = extra["PROTOBUF_GRADLE_PLUGIN_VERSION"].toString()
|
||||||
|
|
||||||
id("com.github.ben-manes.versions") version (gradleVersionsPluginVersion) apply (false)
|
id("com.github.ben-manes.versions") version (gradleVersionsPluginVersion) apply (false)
|
||||||
|
id("com.google.devtools.ksp") version(kspVersion) apply (false)
|
||||||
id("com.google.protobuf") version (protobufVersion) apply (false)
|
id("com.google.protobuf") version (protobufVersion) apply (false)
|
||||||
id("io.gitlab.arturbosch.detekt") version (detektVersion) apply (false)
|
id("io.gitlab.arturbosch.detekt") version (detektVersion) apply (false)
|
||||||
id("org.jetbrains.dokka") version (dokkaVersion) apply (false)
|
id("org.jetbrains.dokka") version (dokkaVersion) apply (false)
|
||||||
|
@ -73,6 +75,7 @@ dependencyResolutionManagement {
|
||||||
// Standalone versions
|
// Standalone versions
|
||||||
version("grpc", grpcVersion)
|
version("grpc", grpcVersion)
|
||||||
version("java", javaVersion)
|
version("java", javaVersion)
|
||||||
|
version("kotlin", kotlinVersion)
|
||||||
version("protoc", protocVersion)
|
version("protoc", protocVersion)
|
||||||
|
|
||||||
// Aliases
|
// Aliases
|
||||||
|
|
Loading…
Reference in New Issue