mirror of
https://github.com/GayPizzaSpecifications/pork.git
synced 2025-08-22 22:01:32 +00:00
ffi: migrate to java.lang.foreign and require Java 21
This commit is contained in:
@ -5,6 +5,7 @@ import org.gradle.api.Plugin
|
||||
import org.gradle.api.Project
|
||||
import org.gradle.api.plugins.JavaPluginExtension
|
||||
import org.gradle.kotlin.dsl.*
|
||||
import org.jetbrains.kotlin.gradle.dsl.KotlinJvmProjectExtension
|
||||
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
|
||||
|
||||
open class PorkModulePlugin : Plugin<Project> {
|
||||
@ -16,13 +17,17 @@ open class PorkModulePlugin : Plugin<Project> {
|
||||
target.repositories.maven(url = "https://gitlab.com/api/v4/projects/49101454/packages/maven")
|
||||
|
||||
target.extensions.getByType<JavaPluginExtension>().apply {
|
||||
val javaVersion = JavaVersion.toVersion(17)
|
||||
val javaVersion = JavaVersion.toVersion(21)
|
||||
sourceCompatibility = javaVersion
|
||||
targetCompatibility = javaVersion
|
||||
}
|
||||
|
||||
target.tasks.withType<KotlinCompile> {
|
||||
kotlinOptions.jvmTarget = "17"
|
||||
kotlinOptions.jvmTarget = "21"
|
||||
}
|
||||
|
||||
target.extensions.getByType<KotlinJvmProjectExtension>().apply {
|
||||
jvmToolchain(21)
|
||||
}
|
||||
|
||||
target.dependencies {
|
||||
|
@ -0,0 +1,8 @@
|
||||
package gay.pizza.pork.buildext
|
||||
|
||||
import org.gradle.api.Plugin
|
||||
import org.gradle.api.Project
|
||||
|
||||
class PorkRootPlugin : Plugin<Project> {
|
||||
override fun apply(target: Project) {}
|
||||
}
|
Reference in New Issue
Block a user