From 01fdeae07d08e818b7765daca7deac89b2cded60 Mon Sep 17 00:00:00 2001 From: Gokhun Celik Date: Mon, 6 May 2024 14:52:51 +0200 Subject: [PATCH] Remove buildDir --- build.gradle | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/build.gradle b/build.gradle index 2f72b55..0dc4384 100644 --- a/build.gradle +++ b/build.gradle @@ -14,7 +14,8 @@ repositories { group = "dev.gokhun" -def generatedSources = "${buildDir}/generated" +def buildDirectory = layout.buildDirectory.getAsFile().get() +def generatedSources = "${buildDirectory}/generated" def taskGroup = "convert" def os = org.gradle.internal.os.OperatingSystem.current() def osName = os.isMacOsX() ? os.getNativePrefix() : os.getFamilyName() @@ -83,6 +84,9 @@ dependencies { application { mainClass = "dev.gokhun.convert.Convert" +} + +java { sourceCompatibility = JavaVersion.VERSION_21 targetCompatibility = JavaVersion.VERSION_21 } @@ -110,10 +114,10 @@ tasks.register("copyBinaries", Copy) { group = taskGroup mustRunAfter("nativeCompile") - def binDir = file("${buildDir}/native/${archiveName}/bin/") + def binDir = file("${buildDirectory}/native/${archiveName}/bin/") binDir.parentFile.mkdirs() - from "${buildDir}/native/nativeCompile/convert" + from "${buildDirectory}/native/nativeCompile/convert" into binDir }